
/* Reset & Base Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f4f4f9;
    margin: 0;
    padding: 0;
    color: #333;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scrollbar-gutter: stable;
    overflow-y: scroll;
}

h3, h4 {
    color: #2c3e50;
    font-weight: 600;
    text-shadow: 0 0 2px rgba(0,0,0,0.1);
}

p {
    line-height: 1.6;
    margin-bottom: 1rem;
}

a {
    color: #0066cc;
    text-decoration: none;
}

    a:hover {
        text-decoration: underline;
    }

/* Layout Styles */
.navbar {
    border-bottom: 2px solid #444;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
    text-shadow: 0 0 3px #fff;
}

.footer {
    padding: 1rem;
    text-align: center;
    background-color: #f0f0f0;
    border-top: 1px solid #ccc;
    font-size: 0.9rem;
}

.page-hero,
.page-status-panel {
    margin-top: 0;
}

.page-hero {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #4a5568;
}

.page-hero h1,
.page-hero .display-4,
.page-hero .home-hero-title {
    font-family: inherit;
    font-size: clamp(2rem, 3.6vw, 2.85rem);
    line-height: 1.08;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #1f2d3d;
    margin-bottom: 1rem;
    overflow-wrap: anywhere;
}

.page-hero .lead,
.page-hero p:not(.small),
.page-hero address {
    font-family: inherit;
    font-size: clamp(1rem, 1.35vw, 1.12rem);
    line-height: 1.6;
    font-weight: 400;
    overflow-wrap: anywhere;
}

.page-hero .small,
.page-hero small {
    font-family: inherit;
    letter-spacing: 0.08em;
}

/* Form Styles */
.form-horizontal {
    margin-top: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

input[type="text"], input[type="email"], input[type="password"] {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.login-credential-field {
    background-color: #c5cedd !important;
}

.btn {
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    box-shadow: none;
    transition: color 0.2s ease-in-out, border-color 0.2s ease-in-out, background-color 0.2s ease-in-out;
}

.btn-primary {
    background-color: rgba(0, 120, 212, 0.08) !important;
    border-color: #0078d4 !important;
    color: #0078d4 !important;
}

    .btn-primary:hover,
    .btn-primary:focus {
        background-color: rgba(0, 120, 212, 0.16) !important;
        border-color: #005fa3 !important;
        color: #005fa3 !important;
        box-shadow: none !important;
    }

/* Card Styles */
.card {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0, 123, 255, 0.2);
    padding: 1rem;
    margin-bottom: 2rem;
}

/* Utility */
.glow {
    box-shadow: 0 0 10px #00f0ff, 0 0 20px #00f0ff;
}

.text-danger {
    color: #a94442;
}

.text-info {
    color: #31708f;
}

.btn-success {
    background-color: rgba(56, 161, 105, 0.08) !important;
    border-color: #38a169 !important;
    color: #2f855a !important;
    box-shadow: none !important;
}

    .btn-success:hover,
    .btn-success:focus {
        background-color: rgba(56, 161, 105, 0.16) !important;
        border-color: #2f855a !important;
        color: #2f855a !important;
        box-shadow: none !important;
    }


.navbar-brand img {
    vertical-align: middle;
    margin-top: -4px; /* adjust as needed */
}

.navbar-brand span {
    position: relative;
    top: -3px; /* adjust as needed */
    display: inline-block;
}

.btn-secondary {
    background-color: rgba(108, 117, 125, 0.08) !important;
    border-color: #6c757d !important;
    color: #5a6268 !important;
    box-shadow: none !important;
}

    .btn-secondary:hover,
    .btn-secondary:focus {
        background-color: rgba(108, 117, 125, 0.16) !important;
        border-color: #545b62 !important;
        color: #545b62 !important;
        box-shadow: none !important;
    }

.external-login-buttons {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
    margin: 0;
    max-width: 240px;
}

.external-login-button {
    width: 100%;
    min-height: 41px;
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    padding: 0 12px;
    border: 1px solid transparent;
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
    line-height: 20px;
    text-align: left;
    white-space: nowrap;
    box-shadow: none;
    transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.external-login-button:hover,
.external-login-button:focus {
    text-decoration: none;
    outline: none;
}

.external-login-button:focus-visible {
    box-shadow: 0 0 0 3px rgba(0, 120, 212, 0.25);
}

.external-login-icon {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.external-login-icon svg {
    display: block;
    width: 100%;
    height: 100%;
}

.external-login-button-text {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
}

.external-login-button-google {
    border-color: #747775;
    color: #1f1f1f;
    font-family: Roboto, Arial, sans-serif;
    font-size: 14px;
    font-weight: 500;
}

.external-login-button-google:hover,
.external-login-button-google:focus {
    background-color: #f8fafd;
    border-color: #5f6368;
    color: #1f1f1f;
}

.external-login-button-microsoft {
    border-color: #8c8c8c;
    border-radius: 0;
    color: #5e5e5e;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    font-size: 15px;
    font-weight: 600;
}

.external-login-button-microsoft:hover,
.external-login-button-microsoft:focus {
    background-color: #f7f7f7;
    border-color: #5e5e5e;
    color: #5e5e5e;
}

.external-login-button-facebook {
    border-color: #1877f2;
    background-color: #1877f2;
    color: #fff;
    font-family: Helvetica, Arial, sans-serif;
    font-size: 15px;
    font-weight: 700;
}

.external-login-button-facebook:hover,
.external-login-button-facebook:focus {
    border-color: #166fe5;
    background-color: #166fe5;
    color: #fff;
}

.btn-outline-info {
    background-color: rgba(43, 108, 176, 0.08) !important;
    border-color: #2b6cb0 !important;
    color: #2b6cb0 !important;
    box-shadow: none !important;
}

    .btn-outline-info:hover,
    .btn-outline-info:focus {
        background-color: rgba(43, 108, 176, 0.16) !important;
        border-color: #1f4f85 !important;
        color: #1f4f85 !important;
        box-shadow: none !important;
    }

.breadcrumb {
    padding: 0;
    margin-bottom: 1.25rem;
    background-color: transparent;
    border-radius: 0;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: #7a8794;
}

.breadcrumb-item.active {
    color: #5f6c79;
}

.result-card {
    min-width: 250px;
}

.result-card .card-header {
    background-color: transparent;
    border-bottom: none;
}

.result-card-description-list {
    border-radius: 6px;
}

.result-card-description-item {
    background-color: rgba(44, 62, 80, 0.03);
    border: none;
    border-radius: 6px;
}

.result-card-footer {
    padding-top: 0;
    background-color: transparent;
    border-top: none;
}

.result-card-actions {
    width: 100%;
}

.result-card-actions-search {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
}

.result-card-actions-details {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.result-card-action {
    margin: 0;
    min-height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.result-card-actions-search .result-card-action,
.result-card-actions-details .result-card-action {
    width: 100%;
}

.merchant-directory-item {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.merchant-directory-summary {
    min-width: 0;
}

.merchant-directory-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    width: 100%;
}

.merchant-directory-action {
    width: 100%;
    min-height: 42px;
}

.result-card-action-primary {
    grid-column: 1 / -1;
}

.result-card-actions-details .result-card-action-primary {
    order: 1;
}

.result-card-actions-details .result-card-action-secondary {
    order: 2;
}

@media (max-width: 575.98px) {
    .body-content {
        padding-left: 12px;
        padding-right: 12px;
    }

    .navbar > .container {
        padding-left: 12px;
        padding-right: 12px;
    }

    .navbar-brand {
        font-size: 1.15rem;
        max-width: calc(100% - 4.75rem);
    }

    .navbar-brand img {
        height: 32px !important;
        margin-right: 8px !important;
    }

    .navbar-brand span {
        top: 0;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .navbar-toggler {
        padding: 0.35rem 0.55rem;
    }

    .jumbotron,
    .about-hero {
        padding: 1.5rem 1.25rem;
        margin-top: 1rem;
        margin-bottom: 1.5rem;
    }

    .page-hero,
    .page-status-panel {
        margin-top: 0;
    }

    .page-hero h1,
    .page-hero .display-4,
    .page-hero .home-hero-title {
        font-size: clamp(1.85rem, 9vw, 2.45rem);
        line-height: 1.08;
    }

    .page-hero .lead,
    .page-hero p:not(.small),
    .page-hero address {
        font-size: 1rem;
    }

    h3 {
        font-size: clamp(1.75rem, 9vw, 2.4rem);
    }

    .card {
        padding: 0.75rem;
        margin-bottom: 1.5rem;
    }

    .card-body,
    .card-footer,
    .card-header {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .result-card-actions-details {
        grid-template-columns: 1fr;
    }

    .merchant-directory-actions {
        width: 100%;
    }

    footer p {
        line-height: 1.8;
        overflow-wrap: anywhere;
    }
}

@media (min-width: 992px) {
    .result-card-actions-details {
        grid-template-columns: minmax(0, 1fr) auto auto;
        align-items: start;
    }

    .result-card-actions-details .result-card-action-primary {
        grid-column: auto;
        min-width: 18rem;
        order: 1;
    }

    .result-card-actions-details .result-card-action-secondary {
        min-width: 10rem;
        order: 2;
    }
}

@media (min-width: 768px) {
    .merchant-directory-item {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 1.5rem;
    }

    .merchant-directory-actions {
        grid-template-columns: repeat(2, minmax(0, 12rem));
        justify-content: end;
        width: auto;
    }

    .merchant-directory-actions-single .merchant-directory-action-latest {
        grid-column: 2;
    }
}

.price-history-chart-shell {
    position: relative;
    height: 20rem;
    min-height: 16rem;
}

.price-history-range {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    margin-top: 0.75rem;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    overflow: hidden;
}

.price-history-range-button {
    min-width: 0;
    padding: 0.65rem 0.5rem;
    border: 0;
    border-left: 1px solid #dee2e6;
    background: #f8f9fa;
    color: #212529;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
}

.price-history-range-button:first-child {
    border-left: 0;
}

.price-history-range-button:hover,
.price-history-range-button:focus {
    background: #e9ecef;
    outline: none;
}

.price-history-range-button:disabled,
.price-history-range-button.disabled {
    background: #e9ecef;
    color: #6c757d;
    cursor: not-allowed;
    opacity: 0.65;
}

.price-history-range-button:disabled:hover,
.price-history-range-button:disabled:focus,
.price-history-range-button.disabled:hover,
.price-history-range-button.disabled:focus {
    background: #e9ecef;
}

.price-history-range-button.active,
.price-history-range-button[aria-pressed="true"] {
    background: #117a8b;
    color: #fff;
}

.price-history-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #dee2e6;
}

.price-history-stat {
    min-width: 0;
}

.price-history-stat span {
    display: block;
    color: #6c757d;
    font-size: 0.8rem;
    line-height: 1.2;
}

.price-history-stat strong {
    display: block;
    color: #212529;
    font-size: 0.95rem;
    line-height: 1.25;
    word-break: break-word;
}

@media (max-width: 767.98px) {
    .price-history-chart-shell {
        height: 18rem;
    }

    .price-history-range {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .price-history-range-button {
        border-top: 1px solid #dee2e6;
    }

    .price-history-range-button:nth-child(-n+2) {
        border-top: 0;
    }

    .price-history-range-button:nth-child(odd) {
        border-left: 0;
    }

    .price-history-range-button:last-child {
        grid-column: 1 / -1;
    }

    .price-history-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.redirectNotice.redirectText {
    display: block;
    margin-top: 0;
    margin-bottom: .5rem;
    font-size: 2rem;
    font-weight: 500;
    line-height: 1.2;
}
