/* ═══════════════════════════════════════════════
   signup.css – Trang Đăng Ký | Gọi Menu
   ═══════════════════════════════════════════════ */

:root {
    --accent: #22c55e;
    --accent-dark: #16a34a;
    --accent-deeper: #15803d;
    --ink: #111827;
    --muted: #6b7280;
    --input-border: #e5e7eb;
    --input-bg: #f9fafb;
    --danger-bg: #fff2ef;
    --danger-border: #f4bbb0;
    --danger-ink: #9a3421;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    font-family: "Be Vietnam Pro", sans-serif;
    background: #eef0f4;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

/* ── Back link ── */
.back-link {
    padding: 18px 28px;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    font-weight: 600;
    color: #1a73e8;
    text-decoration: none;
    cursor: pointer;
}
.back-link:hover { text-decoration: underline; }

/* ── Main wrapper ── */
.main {
    flex: 1;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 16px 48px;
}

/* ── Card ── */
.card {
    position: relative;
    background: #fff;
    border-radius: 20px;
    padding: 20px 45px 40px;
    width: 100%;
    max-width: 590px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.08);
}

/* ── Sticker ── */
.sticker {
    position: absolute;
    left: -18px;
    top: -18px;
    padding: 10px 16px;
    border-radius: 20px;
    background: #22c55e;
    color: #ffffff;
    font-weight: 800;
    font-size: 13px;
    line-height: 1.2;
    transform: rotate(-6deg);
    box-shadow: 0 8px 20px rgba(34, 197, 94, 0.32);
    z-index: 10;
    font-family: "Be Vietnam Pro", sans-serif;
}
.sticker small {
    display: block;
    font-size: 11px;
    opacity: 0.92;
    letter-spacing: 0.4px;
    margin-bottom: 2px;
}

/* ── Logo ── */
.logo-wrap {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 40px;
    font-weight: 900;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}
.logo-g {
    background: #22c55e;
    color: #fff;
    padding: 2px 13px 5px;
    border-radius: 12px;
    font-size: 40px;
    line-height: 1.2;
}
.logo-rest { color: #22c55e; }

.logo-sub {
    font-size: 14px;
    color: #9ca3af;
    font-weight: 500;
    margin-bottom: 22px;
}

/* ── Heading ── */
.heading {
    font-size: 26px;
    font-weight: 800;
    color: var(--ink);
    text-align: center;
    margin-bottom: 6px;
    letter-spacing: -0.3px;
}
.subtext {
    font-size: 14px;
    color: var(--muted);
    text-align: center;
    margin-bottom: 28px;
    line-height: 1.55;
}

/* ── Alert ── */
.alert-box {
    width: 100%;
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 13px;
    line-height: 1.55;
    border: 1px solid var(--danger-border);
    background: var(--danger-bg);
    color: var(--danger-ink);
}
.alert-box ul {
    margin: 0;
    padding-left: 16px;
}

/* ── Form fields ── */
.fields {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.field-wrap {
    position: relative;
    width: 100%;
}

.pill-input {
    width: 100%;
    height: 60px;
    border-radius: 20px;
    border: 1.5px solid var(--input-border);
    background: #fff;
    font-family: "Be Vietnam Pro", sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: var(--ink);
    padding: 26px 20px 10px;
    outline: none;
    transition: all 0.2s;
    appearance: none;
    -webkit-appearance: none;
}

.field-wrap label {
    position: absolute;
    left: 20px;
    top: 18px;
    font-size: 14px;
    color: #9ca3af;
    pointer-events: none;
    transition: all 0.2s;
    font-weight: 500;
}

.pill-input::placeholder { color: transparent; }

.pill-input:focus {
    border-color: #3b82f6;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.pill-input:focus + label,
.pill-input:not(:placeholder-shown) + label {
    top: 10px;
    font-size: 12px;
    color: #6b7280;
    font-weight: 600;
}

/* ── 2-column row ── */
.row2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* ── Password field ── */
.pw-wrap { position: relative; }
.pw-wrap .pill-input { padding-right: 48px; }
.pw-eye {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #9ca3af;
    font-size: 17px;
    padding: 0;
    display: flex;
    align-items: center;
}
.pw-eye:hover { color: #6b7280; }

/* ── Custom select (business type) ── */
.custom-select-wrap { position: relative; }

.btype-option:hover {
    background: #f0fdf4;
    color: var(--accent-dark);
}

/* ── Terms checkbox ── */
.terms-row {
    display: flex;
    align-items: flex-start;
    gap: 9px;
}
.terms-row input[type=checkbox] {
    margin-top: 3px;
    accent-color: var(--accent);
    width: 15px;
    height: 15px;
    flex-shrink: 0;
}
.terms-row label {
    font-size: 13px;
    color: #6b7280;
    line-height: 1.55;
    font-weight: 400;
}
.terms-row a { color: #1a73e8; text-decoration: none; }
.terms-row a:hover { text-decoration: underline; }

/* ── Submit button ── */
.submit-btn {
    width: 100%;
    height: 58px;
    background: var(--accent);
    color: #fff;
    font-family: "Be Vietnam Pro", sans-serif;
    font-size: 17px;
    font-weight: 800;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.2s;
    position: relative;
    box-shadow: 0 8px 24px rgba(34, 197, 94, 0.22);
}
.submit-btn:hover {
    background: var(--accent-dark);
    box-shadow: 0 10px 28px rgba(34, 197, 94, 0.3);
    transform: translateY(-2px);
}
.submit-btn:active { transform: scale(0.98); }

.btn-arrow {
    position: absolute;
    right: 12px;
    width: 34px;
    height: 34px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

/* ── Input icon ── */
.input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #a2b2c3;
    font-size: 17px;
    pointer-events: none;
}

/* ══════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════ */

/* Tablet (≤ 768px) */
@media (max-width: 768px) {
    .card {
        padding: 36px 28px 32px;
        border-radius: 16px;
    }

    .sticker {
        left: -10px;
        top: -14px;
        font-size: 12px;
        padding: 8px 12px;
    }

    .logo-wrap { font-size: 36px; }
    .logo-g    { font-size: 36px; }

    .heading   { font-size: 22px; }
    .subtext   { font-size: 13px; margin-bottom: 20px; }
}

/* Mobile (≤ 480px) */
@media (max-width: 480px) {
    .back-link { padding: 14px 16px; }

    .main { padding: 0 12px 36px; }

    .card {
        padding: 32px 18px 28px;
        border-radius: 14px;
        margin-top: 8px;
    }

    /* Sticker ẩn trên màn hình rất nhỏ để tránh bị cắt */
    .sticker { display: none; }

    .logo-wrap { font-size: 30px; }
    .logo-g    { font-size: 30px; padding: 2px 10px 4px; }

    .heading   { font-size: 20px; }
    .subtext   { font-size: 13px; margin-bottom: 18px; }

    /* 2 cột → 1 cột */
    .row2 { grid-template-columns: 1fr; }

    /* Input nhỏ hơn một chút */
    .pill-input { height: 54px; font-size: 14px; }

    .field-wrap label { font-size: 13px; top: 16px; }

    .pill-input:focus + label,
    .pill-input:not(:placeholder-shown) + label {
        top: 8px;
        font-size: 11px;
    }

    /* Custom select button */
    #btype-btn { height: 54px; }

    .submit-btn { height: 52px; font-size: 15px; }

    .terms-row label { font-size: 12px; }
}

/* Rất nhỏ (≤ 360px) */
@media (max-width: 360px) {
    .card { padding: 28px 14px 24px; }
    .logo-wrap { font-size: 26px; }
    .logo-g    { font-size: 26px; }
    .heading   { font-size: 18px; }
}

/* ── Toast Container & Cards (Top-right corner) ── */
#toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.toast-card {
    pointer-events: auto;
    width: 330px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-left: 5px solid #22c55e;
    border-radius: 14px;
    padding: 14px 18px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateX(120%);
    opacity: 0;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toast-card.show {
    transform: translateX(0);
    opacity: 1;
}

.toast-card.toast-error {
    border-left-color: #ef4444;
}

.toast-card.toast-success {
    border-left-color: #22c55e;
}

.toast-card .toast-icon {
    font-size: 20px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toast-card.toast-error .toast-icon {
    color: #ef4444;
}

.toast-card.toast-success .toast-icon {
    color: #22c55e;
}

.toast-card .toast-message {
    font-size: 13.5px;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.4;
}

/* ── Error validation red borders ── */
.pill-input.is-invalid,
.custom-select-btn.is-invalid {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1) !important;
}

