/* Auth and dashboard specific styles */
:root {
    --bg: #f7f8fb;
    --card: #ffffff;
    --accent: #ff6b6b;
    --muted: #6b7280;
}

body {
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    margin: 0;
    background: var(--bg);
    color: #0b1220;
}

.form-container {
    max-width: 460px;
    margin: 28px auto;
    background: var(--card);
    padding: 22px 20px;
    border-radius: 10px;
    box-shadow: 0 18px 40px rgba(11, 18, 32, 0.06);
}

.form-container label {
    display: block;
    margin-bottom: 12px;
    font-size: 14px;
    color: #222;
    position: relative;
}

.form-container input[type="password"],
.form-container input[type="text"] {
    width: 100%;
    padding: 8px 35px 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
}

.show-code-btn {
    position: absolute;
    right: 12px;
    top: calc(50% + 11px);
    transform: translateY(-50%);
    background: transparent !important;
    border: none !important;
    outline: none;
    padding: 0 !important;
    margin: 0 !important;
    width: 20px;
    height: 20px;
    cursor: pointer;
    font-size: 0;
    box-shadow: none !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.show-code-btn:hover {
    opacity: 0.7;
    transform: translateY(-50%) !important;
    background: transparent !important;
    box-shadow: none !important;
}

.show-code-btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23555555'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M15 12a3 3 0 11-6 0 3 3 0 016 0z'/%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

.form-container input {
    width: 100%;
    padding: 10px;
    margin-top: 6px;
    box-sizing: border-box;
    border: 1px solid #e6e9ee;
    border-radius: 8px
}

.form-container button[type="submit"] {
    width: 100%;
    padding: 12px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600
}

.form-container button[type="submit"]:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(255, 107, 107, 0.12)
}

.form-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: var(--nav-bg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    margin-bottom: 20px;
    position: relative;
}

.form-header a {
    text-decoration: none;
    color: #fff;
}

.form-header h2 {
    color: #fff;
}

.profile-menu-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
}

.profile-menu-wrapper:hover {
    background: rgba(255, 255, 255, 0.15);
}

.profile-menu-wrapper .user-name {
    color: #fff;
    font-weight: 500;
}

#profilePic {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.2);
    background: #fff;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.profile-dropdown {
    position: absolute;
    top: calc(100% + 5px);
    right: 0;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
}

.profile-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu {
    padding: 8px 0;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    /* This contains the hover effect */
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #0b1220;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-size: 14px;
    font-weight: 500;
    margin: 0;
    /* Remove any margin */
}

.menu-item:hover {
    background-color: #464646;
    color: white;
    width: 100%;
    margin: 0;
    border-radius: 0;
    /* Remove any border radius on hover */
}

.menu-icon {
    font-size: 18px;
}

.logout-item {
    border-top: 1px solid #eee;
    color: #0b1220;
    width: 100%;
    margin: 0;
}

.logout-item:hover {
    background-color: #4cae4c;
    color: white;
}

.muted {
    color: var(--muted);
    font-size: 13px;
    margin-top: 8px
}

.msg {
    color: #ef4444;
    margin-top: 8px;
    font-size: 13px
}

.dashboard {
    max-width: 860px;
    margin: 28px auto;
    background: var(--card);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 12px 28px rgba(11, 18, 32, 0.05)
}

.header-right {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-info img#profilePic {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(0, 0, 0, 0.06);
    background: #fff;
}

.user-name {
    color: #0b1220;
    /* darker text by default; on white cards this will be dark */
    font-weight: 600;
}

.logout {
    padding: 6px 10px;
    background: #ef4444;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
}

/* small reveal animation for forms */
.form-container {
    opacity: 0;
    transform: translateY(10px);
    animation: fadeUp .6s ease .05s forwards
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(10px)
    }

    to {
        opacity: 1;
        transform: none
    }
}

/* Dashboard search (placed under the dashboard card)
   centered with max-width similar to the card */
.dashboard-search {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 14px auto 0;
    max-width: 900px;
    padding: 6px
}

.dashboard-search input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #e6e9ee;
    border-radius: 8px;
    font-size: 14px
}

.dashboard-search button {
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px
}

.search-results {
    margin: 18px auto 0;
    background: var(--card);
    padding: 12px 16px;
    border-radius: 10px;
    border: 1px solid rgba(0, 0, 0, 0.04);
    min-height: 48px;
    color: #111;
    max-width: 900px;
    box-shadow: 0 10px 30px rgba(11, 18, 32, 0.04)
}

/* Dropdown Menu Styles */
.profile-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: var(--card);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1000;
    color: white;
}

.profile-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.profile-dropdown:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.dropdown-menu {
    padding: 8px 0;
    background: #000000;
    border-radius: 12px;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #0b1220;
    /* Dark text color by default */
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-size: 14px;
    font-weight: 500;
}

.menu-item:hover {
    background-color: #464646;
    color: white;

}

/* Special styling for logout item remains the same */
.logout-item {
    border-top: 1px solid #eee;
    color: #ffffff;
}

.logout-item:hover {
    background-color: #4cae4c;
    color: white;
}

.sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0
}

/* Google Sign-In Button Styles */
.google-signin-btn {
    width: 100%;
    padding: 12px 16px;
    background-color: #4285f4;
    color: #ffffff;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 500;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.2s ease-in-out;
    box-sizing: border-box;
}

.google-signin-btn:hover {
    background-color: #357ae8;
    box-shadow: 0 2px 8px rgba(66, 133, 244, 0.3);
}

.google-signin-btn:active {
    background-color: #2d5ac9;
}

.google-signin-btn:disabled {
    background-color: #4285f4;
    color: rgba(255, 255, 255, 0.6);
    cursor: not-allowed;
    opacity: 0.7;
}

.google-signin-btn span {
    letter-spacing: 0.25px;
}

.google-logo {
    width: 20px;
    height: 20px;
    background-color: #ffffff;
    color: #4285f4;
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    flex-shrink: 0;
}