@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --bg: #f4f3fb;
    --surface: #ffffff;
    --surface-soft: #f8f7ff;
    --text: #1f1a33;
    --text-muted: #6e6892;
    --primary: #6b4de6;
    --primary-soft: #efeaff;
    --border: #e8e3f8;
    --success: #2ea970;
    --warning: #f2a53a;
    --danger: #e04d66;
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --shadow-card: 0 10px 30px -18px rgba(53, 33, 113, 0.32);
    --sidebar-width: 260px;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
}

body {
    font-family: 'Plus Jakarta Sans', 'Segoe UI', sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 12% 8%, #ffffff 0%, transparent 28%),
        radial-gradient(circle at 92% 0%, #f1eeff 0%, transparent 26%),
        linear-gradient(180deg, #f9f8ff 0%, #f1effa 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

.container {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr;
    min-height: 100dvh;
}

.sidebar {
    background: var(--surface);
    border-right: 1px solid var(--border);
    padding: 22px 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.profile {
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: 18px;
    text-align: center;
    padding: 18px 12px 14px;
}

.profile-image {
    width: 74px;
    height: 74px;
    margin: 0 auto 12px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #7f65ea 0%, #5f45d2 100%);
    color: #fff;
    font-size: 40px;
    box-shadow: 0 10px 20px -12px rgba(73, 45, 160, 0.8);
}

#user-name {
    margin: 0 0 4px;
    font-size: 16px;
    font-weight: 700;
    max-width: 100%;
    line-height: 1.3;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.profile .user-email-short {
    margin: 0;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
    white-space: normal;
}

.profile .user-email-full {
    margin: 2px 0 0;
    color: #9a95b6;
    font-size: 11px;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.sidebar nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sidebar nav li {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    border-radius: 12px;
    padding: 0 12px;
    font-size: 14px;
    font-weight: 600;
    color: #4a4565;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

.sidebar nav li i {
    width: 18px;
    text-align: center;
    color: #7b6eb6;
}

.sidebar nav li:hover {
    background: #f6f4ff;
    border-color: var(--border);
}

.sidebar nav li.active {
    background: linear-gradient(90deg, #ece7ff 0%, #f3f0ff 100%);
    border-color: #ddd6ff;
    color: #2f2850;
}

.sidebar nav li.active i {
    color: var(--primary);
}

.main-content {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.main-content>header {
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border);
    padding: 14px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 20;
}

.main-content>header h1 {
    margin: 0;
    font-size: 32px;
    letter-spacing: -0.8px;
    font-weight: 800;
    background: linear-gradient(135deg, #4d3bb0 0%, #7a62e9 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.main-content>header nav {
    display: flex;
    align-items: center;
    gap: 14px;
}

.main-content>header nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 38px;
    padding: 0 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    color: #3f395d;
    background: #f7f5ff;
    border: 1px solid var(--border);
}

.main-content>header nav a:hover {
    background: #efebff;
}

.logout {
    height: 38px;
    border: 0;
    border-radius: 10px;
    padding: 0 15px;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #7458ea 0%, #5d45d7 100%);
    cursor: pointer;
    box-shadow: 0 8px 20px -14px rgba(82, 63, 168, 0.9);
}

.dashboard {
    padding: 22px;
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
    grid-template-areas:
        'activity activity'
        'quick quick'
        'advisors advisors';
    gap: 18px;
}

.dashboard>div {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 18px;
}

.activity {
    grid-area: activity;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.activity .card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    min-height: 84px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    font-weight: 700;
    color: #2a2445;
    box-shadow: var(--shadow-card);
}

.activity .card i {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    font-size: 15px;
    color: #fff;
    background: linear-gradient(135deg, #8e73f4 0%, #6a53e0 100%);
}

.activity .card span {
    font-size: 30px;
    line-height: 1;
    font-weight: 800;
    margin-right: 6px;
    color: #1f1a33;
}

.light-yellow {
    background: linear-gradient(180deg, #fff 0%, #faf8ff 100%);
}

.light-red {
    background: linear-gradient(180deg, #fff 0%, #f9f7ff 100%);
}

.quick-actions {
    grid-area: quick;
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.quick-action-card {
    min-height: 78px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: #fbfaff;
    color: #342d54;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 700;
    transition: all 0.2s ease;
    box-shadow: 0 6px 16px -14px rgba(61, 44, 128, 0.45);
}

.quick-action-card i {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 14px;
    background: linear-gradient(135deg, #8e73f4 0%, #6a53e0 100%);
}

.quick-action-text {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.quick-action-title {
    color: #2f284a;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.25;
}

.quick-action-subtitle {
    color: #8f88ad;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.quick-action-arrow {
    width: auto;
    height: auto;
    border-radius: 0;
    color: #978fbd;
    background: transparent;
    font-size: 12px;
    margin-left: 8px;
    flex-shrink: 0;
    opacity: 1;
    visibility: visible;
}

.quick-action-card:hover {
    transform: translateY(-2px);
    border-color: #d7d0f8;
    background: #f5f2ff;
}

.quick-action-card:hover i.quick-action-arrow,
.quick-action-card:focus-visible i.quick-action-arrow {
    color: #776bb0;
    background: transparent;
    opacity: 1;
    visibility: visible;
}

.meetings {
    grid-area: meetings;
}

.checklist {
    grid-area: checklist;
}

.advisors {
    grid-area: advisors;
}

.dashboard h3 {
    margin: 0 0 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 20px;
    font-weight: 800;
}

.dashboard h3 i {
    color: var(--primary);
    font-size: 18px;
}

#meetings-content,
#checklist-content {
    margin: 0;
    color: var(--text-muted);
    font-size: 14px;
}

#advisors-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.advisor-card {
    display: grid;
    grid-template-columns: 42px 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: #f8f6ff;
}

.advisor-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 15px;
    font-weight: 800;
    color: #fff;
    background: linear-gradient(135deg, #8e73f4 0%, #6a53e0 100%);
}

.advisor-meta h4 {
    margin: 0;
    color: #2f2949;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
}

.advisor-role,
.advisor-phone {
    margin: 4px 0 0;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #7b739f;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.25;
}

.advisor-role i,
.advisor-phone i {
    color: #8a81b3;
    width: 12px;
    text-align: center;
}

.advisor-phone a {
    color: var(--primary);
    font-weight: 800;
}

.advisor-actions {
    display: grid;
    gap: 6px;
    justify-items: end;
}

.advisor-btn {
    min-width: 88px;
    height: 28px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    border: 1px solid transparent;
    text-decoration: none;
}

.advisor-call {
    color: #fff;
    background: linear-gradient(135deg, #7e62ea 0%, #684fd9 100%);
}

.advisor-call i {
    color: #fff;
}

.advisor-msg {
    color: #6e6596;
    background: #f0ebff;
    border-color: #ddd5ff;
}

.advisor-msg i {
    color: #6e6596;
}

.advisor-btn:hover {
    filter: brightness(0.98);
}

.student-details,
.course-finder-prefs,
.liked-courses {
    margin: 22px;
    background: transparent;
}

.student-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 18px;
}

.details-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 18px;
}

.details-card h3 {
    margin: 0 0 14px;
    font-size: 16px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
}

.details-card h3 i {
    color: var(--primary);
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

.details-grid label {
    display: block;
    margin-bottom: 5px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: #8e89ad;
}

.details-grid p {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #372f57;
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.chip {
    height: 34px;
    border-radius: 999px;
    border: 1px solid #ddd7f7;
    background: #f7f5ff;
    color: #4f4678;
    font-size: 12px;
    font-weight: 700;
    padding: 0 14px;
    cursor: pointer;
}

.chip.selected {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, #7f65ea 0%, #5f45d2 100%);
}

.course-finder-prefs {
    border-radius: var(--radius-lg);
}

.course-finder-prefs h3,
.liked-courses h3 {
    margin: 0 0 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 22px;
    font-weight: 800;
}

.course-finder-prefs h3 i,
.liked-courses h3 i {
    color: var(--primary);
}

.preferences-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.pref-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 18px;
}

.pref-card h4 {
    margin: 0 0 12px;
    color: #352e55;
    font-size: 16px;
    font-weight: 800;
}

.pref-content {
    margin-bottom: 10px;
}

.pref-content:last-child {
    margin-bottom: 0;
}

.pref-content label {
    display: block;
    margin-bottom: 4px;
    color: #8c86ac;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.pref-content p {
    margin: 0;
    color: #3f385f;
    font-size: 14px;
    font-weight: 700;
}

.liked-courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 16px;
}

.liked-course-card {
    display: flex;
    flex-direction: column;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-card);
}

.liked-course-image {
    height: 135px;
    background: #f2efff;
}

.liked-course-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.liked-course-details {
    padding: 14px;
}

.liked-course-details h4 {
    margin: 0 0 10px;
    font-size: 16px;
    color: #2c2548;
}

.liked-course-details p {
    margin: 0 0 6px;
    font-size: 13px;
    color: #564f75;
}

.liked-course-details p strong {
    color: #2e274c;
}

@media (max-width: 1080px) {
    .container {
        grid-template-columns: 230px 1fr;
    }

    .main-content>header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .main-content>header nav {
        flex-wrap: wrap;
    }
}

@media (max-width: 900px) {
    .container {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        border-right: 0;
        border-bottom: 1px solid var(--border);
    }

    .dashboard {
        grid-template-columns: 1fr;
        grid-template-areas:
            'activity'
            'quick'
            'advisors';
    }
}

@media (max-width: 640px) {
    .activity {
        grid-template-columns: 1fr;
    }

    .quick-actions-grid {
        grid-template-columns: 1fr;
    }

    #advisors-list {
        grid-template-columns: 1fr;
    }

    .advisor-card {
        grid-template-columns: 40px 1fr;
        row-gap: 8px;
    }

    .advisor-actions {
        grid-column: 1 / -1;
        justify-items: stretch;
        grid-template-columns: 1fr 1fr;
    }

    .advisor-btn {
        width: 100%;
    }

    .main-content>header h1 {
        font-size: 27px;
    }

    .main-content>header nav {
        gap: 8px;
    }

    .main-content>header nav a,
    .logout {
        height: 36px;
        padding: 0 12px;
    }
}