/* General Reset and Basic Styling */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
    max-width: 100%;
    overflow-x: hidden;
}
body {
    font-family: "Inter", sans-serif;
    background-color: #fff;
    color: rgb(51, 52, 97);
}

/* Plain body copy - matches the homepage's paragraph proportions (.dna-text p /
   .wrapper p) so text isn't left at the bare, unspaced browser default outside
   those specific containers. More specific rules (.wrapper p, .card-meta, etc.)
   still win via specificity, this is just the fallback baseline. */
p {
    font-size: 15px;
    line-height: 1.6;
    color: var(--color-text-subtle);
    margin-bottom: 12px;
}

ul, ol {
    padding-left: 22px;
    margin-bottom: 12px;
}

li {
    font-size: 15px;
    line-height: 1.6;
    color: var(--color-text-subtle);
    margin-bottom: 6px;
}

header {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    gap: 16px;
}

.wrapper {
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}
.no-select {
    user-select: none;
    -webkit-user-select: none;
}

header .wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

/* Wider container for the public marketing pages (home/news/help/contact) */
.home-wrap {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    padding: 0 24px;
}
.home-wrap-narrow {
    max-width: 640px;
}

.help-entry {
    padding: 20px 0;
    border-top: 1px solid #eee;
}
.help-entry h3 {
    font-size: 17px;
    margin-bottom: 8px;
}
.help-entry img {
    max-width: 100%;
}

.captcha-img {
    border-radius: 8px;
    border: 1px solid #ddd;
    vertical-align: middle;
}

/* ===============================
   📅 GRADEBOOK GRID
================================ */
.gradebook-grid-wrapper {
    overflow-x: auto;
    max-width: 100%;
    border: 1px solid #ddd;
    border-radius: var(--radius-lg);
}
.gradebook-grid {
    border-collapse: separate;
    border-spacing: 0;
    width: max-content;
}
.gradebook-grid th, .gradebook-grid td {
    border: 1px solid #eee;
    padding: 6px 8px;
    text-align: center;
    font-size: 13px;
    white-space: nowrap;
}
.gradebook-grid thead th {
    background: var(--color-bg-muted);
    font-weight: 600;
    position: sticky;
    top: 0;
    z-index: 1;
}
.gradebook-frozen {
    position: sticky;
    background: #fff;
    z-index: 2;
    text-align: left;
}
.gradebook-frozen-nr { left: 0; width: 40px; }
.gradebook-frozen-sname { left: 40px; width: 140px; }
.gradebook-frozen-fname { left: 180px; width: 140px; }
/* Higher specificity than ".gradebook-grid thead th" above, which would otherwise win the
   z-index tug-of-war (it's more specific than a plain "thead .gradebook-frozen" rule) and
   leave the frozen Nr/Pavardė/Vardas header cells sitting under the scrolling day columns. */
.gradebook-grid thead th.gradebook-frozen { z-index: 3; background: var(--color-bg-muted); }
.gradebook-month {
    background: var(--color-bg-muted);
    font-weight: 600;
}
.gradebook-day {
    width: 32px;
    min-width: 32px;
}
.gradebook-weekend {
    background: #fdf1f1;
    font-weight: 600;
}
.gradebook-today {
    background: #e6f9f3;
    box-shadow: inset 0 0 0 2px var(--color-primary);
}
.gradebook-day-header {
    cursor: pointer;
}
.gradebook-marker-tags {
    display: flex;
    gap: 2px;
    justify-content: center;
    margin-top: 2px;
}
.gradebook-marker-tag {
    font-size: 9px;
    font-weight: 700;
    line-height: 1;
    background: var(--color-primary);
    color: #fff;
    border-radius: 3px;
    padding: 1px 3px;
}
.gradebook-cell {
    cursor: pointer;
    font-weight: 600;
}
.gradebook-cell:hover {
    background: var(--color-bg-muted);
}
.gradebook-has-note {
    position: relative;
}
.gradebook-has-note::after {
    content: '';
    position: absolute;
    top: 2px;
    right: 2px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--color-primary-dark);
}
header .home-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.public-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lang-switch-trigger {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-main);
    cursor: pointer;
}

.lang-switch-trigger a {
    color: var(--color-text-muted);
    font-weight: 600;
    text-decoration: none;
}

.lang-switch-trigger a.active {
    color: var(--color-primary-dark);
}

.lang-switch-trigger a:hover {
    text-decoration: underline;
}

.header-help-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: var(--color-text-muted);
    font-size: 16px;
    text-decoration: none;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.header-help-btn:hover {
    background: var(--color-bg-muted);
    color: var(--color-primary-dark);
}

.logo {
    font-size: 22px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 8px;
}
.logo i {
    color: var(--color-primary);
}
nav.mainmenu {
    background-color: rgb(250, 248, 246);
    padding: 10px;
    text-align: center;
}

/* Shared pill-nav-link look for both the public home nav and the tutor/student
   internal nav - they only differ in how their container lays out the children. */
.public-nav a,
nav.mainmenu a {
    padding: 8px 16px;
    border-radius: 20px;
    color: var(--color-text-main);
    font-weight: 500;
    font-size: 14px;
    text-decoration: none;
    transition: background-color 0.15s ease, color 0.15s ease;
}
nav.mainmenu a {
    margin: 0 4px;
    display: inline-block;
}

.public-nav a:hover {
    background: var(--color-bg-muted);
}
nav.mainmenu a:hover {
    color: var(--color-primary-dark);
    background-color: #fff;
}

.public-nav a.active,
nav.mainmenu a.active {
    background-color: #e6f9f3;
    color: var(--color-primary-dark);
    font-weight: 600;
}

main {
    padding: 20px;
}
footer {
    background-color: #f8f9fa;
    padding: 15px;
    text-align: center;
    color: rgb(51, 52, 97);
    font-size: 0.9em;
    margin-top: 20px;
    border-top: 1px solid #ddd;
}

.item-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgb(250, 248, 246);
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: transform 0.2s ease;
    text-align: center;
    padding: 8px;
}

.dropdown-menu {
    position: relative;
    display: flex;
    align-items: center;
}

.item-logo.avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background-color: var(--color-primary);
    color: #fff;
    font-weight: 700;
    font-size: 15px;
}
.dropdown-menu:hover .dropdown {
    display: block;
}

.dropdown-trigger:hover {
    transform: scale(1.1);
}
.dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background-color: #fff;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    z-index: 1;
    border-radius: 5px;
    min-width: 190px;
    margin-top: 2px;
    border: 1px solid #ddd;
    font-size:14px;
}
.dropdown a {
    color: rgb(51, 52, 97);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
    transition: background-color 0.3s ease;
    border-bottom: 1px solid #eee;
}
.dropdown a:last-child{
    border-bottom: none;
}
.dropdown a:hover {
    background-color: #e9ecef;
}


/* --- Main Content Styles --- */
.wrapper h2 {
    font-size: 24px;
    margin-bottom: 15px;
}
.wrapper p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 20px;
    color: #555;
}


table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    background-color: #fff;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow: hidden;
}
th, td {
    border-bottom: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}
th {
    background-color: #f2f2f2;
    font-weight: bold;
}

td .description {
    display: block;
    font-size: 0.8em;
    color: #6c757d;
}
tr .narrow {
    width: 1%;
    white-space: nowrap;
}

tbody tr:hover {
    background-color: var(--color-bg-muted);
}

tr.highlight-row {
    background-color: #e6f9f3;
    font-weight: 600;
}

.booking-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px 0;
}

.booking-row-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.booking-move-select {
    width: auto;
    margin: 0;
    padding: 6px 8px;
    font-size: 13px;
}

.waitlist-divider {
    margin: 8px 0;
    border: none;
    border-top: 1px dashed #ddd;
}

.waitlist-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--color-warning);
    margin-bottom: 4px;
}

.access-code {
    background-color: #e6f9f3;
    color: var(--color-primary-dark);
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
}

.edit-icon {
    margin-right: 5px;
    cursor: pointer;
    color: #0265b2;
}

.delete-icon {
    margin-left: 5px;
    cursor: pointer;
    color: #dc3545;
}
.add-icon {
    margin-left: 5px;
    cursor: pointer;
    color: #28a745;
}

.fa-image {
    color: var(--color-text-muted);
}



@media (max-width: 480px){
    .logo{
        font-size: 20px;
    }
    .item-logo{
        width: 35px;
        height: 35px;
    }
    nav.mainmenu a{
        padding: 10px 5px;
    }
}






/* Form Container Styles */
.login-box {
    width: 100%;
    max-width: 400px;
    text-align: left;
    padding: 20px 0;
}

.form-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.form-box {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    background-color: #ffffff;
    text-align: left;
}

.form-box label,
.login-box label,
.wrapper label,
.home-wrap label {
    display: block;
    margin-top: 8px;
    font-weight: 600;
    color: #333;
}

.form-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 24px;
}

input[type="radio"],
input[type="checkbox"] {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="password"],
input[type="file"],
input[type="datetime-local"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 12px;
    margin: 8px 0;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    background-color: #fafafa;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
input[type="password"]:focus,
input[type="file"]:focus,
input[type="datetime-local"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #b2b2b2;
}



.group-meta {
    color: var(--color-text-muted);
    font-size: 13px;
    margin-top: -8px;
    margin-bottom: 16px;
}

.item-label {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    margin: 0 6px;
    vertical-align: middle;
    background-color: rgba(0,0,0,0.04); /* fallback, can be overridden inline */
    border: 1px solid rgba(0,0,0,0.08);
    transition: background-color 0.2s, color 0.2s;
}

/* Keeps a group of item-labels in one horizontal row instead of wrapping/stacking
   when the containing cell is narrow (e.g. per-question answer-stat badges). */
.item-label-row {
    display: flex;
    align-items: center;
    gap: 4px;
}

.item-label-row .item-label {
    margin: 0;
    white-space: nowrap;
}

.divider {
    display: flex;
    align-items: center;
    text-align: center;
    color: #8e8e8e;
    margin: 20px 0;
}

.divider::before,
.divider::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid #ddd;
}

.divider::before {
    margin-right: 12px;
}

.divider::after {
    margin-left: 12px;
}

.social-login {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
}

.social-button {
    padding: 12px;
    border: none;
    border-radius: 4px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    display: block;
    text-align: center;
    text-decoration: none;
}

.google {
    background-color: #db4437;
    color: #fff;
}

.google:hover {
    background-color: #c33727;
}

.form-footer {
    margin-top: 20px;
    font-size: 14px;
    color: #8e8e8e;
}
a {
    color: #0265b2;
    text-decoration: none;
    font-weight: 600;
}

a.disabled {
    color: #ccc;
}

a:hover {
    text-decoration: underline;
}

.remember-me {
    display: flex;
    align-items: center;
    margin-top: 6px;
    gap: 12px;
}

.remember-me label {
    display: inline;
    margin-top: 0;
    font-weight: 400;
    color: inherit;
}

.remember-me input[type="checkbox"],
.remember-me input[type="radio"] {
    accent-color: #20AD95;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.answer-review-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    cursor: default;
}

.toggle-arrow {
    font-size: 11px;
    display: inline-block;
    margin-left: 4px;
}

.answer-tag {
    font-size: 12px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    white-space: nowrap;
}

.answer-tag.correct {
    background: #e6f9f3;
    color: var(--color-success);
}

.wrong-pick {
    color: var(--color-alert);
    font-weight: 600;
}
.correct-pick {
    color: var(--color-success);
    font-weight: 600;
}





h1 {
    font-size: 26px;
    font-weight: 600;
    color: rgb(51, 52, 97);
    line-height: 1.3;
    margin: 0;
    padding: 9px 0 4px;
}
h2 {
    font-size: 22px;
    font-weight: 600;
    color: rgb(51, 52, 97);
    line-height: 1.3;
    margin: 0;
    padding: 6px 0 4px;
}

/* msg that appears on the top of the page */
.page-message {
    display: inline-block;
    padding: 6px 16px;
    width:100%;
    border-radius: 6px;
    background: #fff;
    color: #333;
    border: 1px solid #e0e0e0;
    font-weight: 500;
    opacity: 0.98;
    margin-bottom: 20px;
}

.page-message.success {
    background: #e6f9f3;
    color: #218875;
    border-color: #b6f0e0;
}

.page-message.error {
    background: #fdeaea;
    color: #dc3545;
    border-color: #f5c2c7;
}

.page-message.info {
    background: #eaf4fd;
    color: #1766a3;
    border-color: #b6d8f5;
}

.booking-dialog {
    border: none;
    border-radius: var(--radius-lg);
    padding: 24px;
    width: min(460px, calc(100vw - 32px));
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
    margin: auto;
}

.booking-dialog::backdrop {
    background: rgba(31, 42, 68, 0.45);
}

.booking-dialog h2 {
    font-size: 20px;
    margin-bottom: 12px;
}

.booking-dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
}

.datetime-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.datetime-row input {
    flex: 1;
    width: auto;
    min-width: 0;
}

.btn-now {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 50%;
    background: #1766a3;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-now:hover {
    background: #0f4f82;
}

p.field-error-text {
    display: none;
    color: #dc3545;
    font-size: 12px;
    margin: -4px 0 10px;
}

p.field-error-text.is-visible {
    display: block;
}

input.field-invalid {
    border-color: #dc3545;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.filter-btn {
    padding: 5px 14px;
    border-radius: 20px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    font-family: inherit;
    color: #555;
    text-decoration: none;
    display: inline-block;
    transition: all 0.15s ease;
}

.filter-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.filter-btn.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
    font-weight: 600;
}


.loader {
        border: 4px solid #f3f3f3;
        border-top: 4px solid #3498db;
        border-radius: 50%;
        width: 24px;
        height: 24px;
        animation: spin 1s linear infinite;
        display: inline-block;
        vertical-align: middle;
        margin-left: 10px;
    }

    @keyframes spin {
        0% { transform: rotate(0deg); }
        100% { transform: rotate(360deg); }
    }

    .hidden {
        display: none !important;
    }


/* ===============================
   🎨 DESIGN TOKENS
================================ */
:root {
    --color-primary: #20b095;
    --color-primary-dark: #1a9b83;

    --color-secondary: #eaeaea;
    --color-secondary-dark: #cacaca;

    --color-alert: #c43b3b;
    --color-alert-dark: #a94442;

    --color-text-main: #1f2a44;
    --color-text-muted: #718096;
    --color-text-subtle: #4a5568;

    --color-bg-card: #ffffff;
    --color-bg-muted: #f7f8fa;

    --color-success: #1f9d55;
    --color-success-dark: #187a43;
    --color-warning: #b7791f;
    --color-muted: #a0aec0;

    --radius-lg: 10px;
    --radius-md: 6px;

    --shadow-card: 0 4px 14px rgba(0,0,0,0.06);
}

/* ===============================
   ✍️ TYPOGRAPHY
================================ */
.card-subtitle {
    font-size: 14px;
    color: var(--color-text-subtle);
}

.card-meta {
    font-size: 13px;
    color: var(--color-text-muted);
}

p.field-hint {
    font-size: 12px;
    color: #a0aec0;
}

.meeting-info-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 24px;
}

.pagination-info {
    font-size: 14px;
    color: var(--color-text-muted);
}

.group-member-accordion {
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    margin-bottom: 14px;
    overflow: hidden;
}

.group-member-accordion summary {
    cursor: pointer;
    padding: 16px 20px;
    font-weight: 600;
    font-size: 17px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    list-style: none;
    background: #d4f0e8;
}

.group-member-accordion summary::-webkit-details-marker {
    display: none;
}

.group-member-accordion summary .meeting-card-toggle-icon {
    color: var(--color-text-muted);
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.group-member-accordion[open] summary .meeting-card-toggle-icon {
    transform: rotate(180deg);
}

.group-member-accordion-body {
    padding: 16px 20px;
}

.meeting-info-row i {
    color: var(--color-text-muted);
    width: 15px;
    text-align: center;
    margin-top: 4px;
    flex-shrink: 0;
}

.faq-section-title {
    font-size: 19px;
    margin: 32px 0 14px;
}

.faq-section-title:first-of-type {
    margin-top: 8px;
}

.faq-item {
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    background: var(--color-bg-card);
    margin-bottom: 10px;
    overflow: hidden;
}

.faq-item summary {
    cursor: pointer;
    padding: 16px 20px;
    font-weight: 600;
    color: var(--color-text-main);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    list-style: none;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary i {
    color: var(--color-text-muted);
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.faq-item[open] summary i {
    transform: rotate(180deg);
}

p.faq-answer {
    padding: 0 20px 18px;
    margin: 0;
    color: var(--color-text-subtle);
}

.form-section {
    background: var(--color-bg-muted);
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    padding: 16px 18px;
    margin: 16px 0;
}

.form-section .remember-me {
    margin-top: 0;
}

.form-section #recurrenceFields {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e2e2e2;
}

/* ===============================
   🟢 STATUS LABELS
================================ */
.status {
    font-size: 13px;
    font-weight: 600;
}

.status-active {
    color: var(--color-success);
}

.status-pending {
    color: var(--color-warning);
}

.status-finished {
    color: var(--color-muted);
}

.status-alert {
    color: var(--color-alert);
}

/* ===============================
   🔘 BUTTONS
================================ */
.btn {
    font-family: inherit;
    font-size: 14px;
    text-align: center;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 10px 16px;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: all 0.15s ease;
    cursor: pointer;
}

.btn-primary {
    background: var(--color-primary);
    color: #fff;
    border: 1px solid var(--color-primary-dark);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
}

.btn-secondary {
    background: var(--color-secondary);
    color: #555;
    border: 1px solid var(--color-secondary-dark);
}

.btn-secondary:hover {
    background: var(--color-secondary-dark);
}

.btn-alert {
    background: var(--color-alert);
    color: #fff;
    border: 1px solid var(--color-alert-dark);
}

.btn-alert:hover {
    background: var(--color-alert-dark);
}

.btn-new {
    background: var(--color-secondary);
    color: #555;
    border: 1px solid var(--color-secondary-dark);
}

.btn-new:hover {
    background: var(--color-primary);
    color: #fff;
    border: 1px solid var(--color-primary-dark);
    text-decoration: none;
}

.btn-outline {
    background: #fff;
    color: var(--color-text-main);
    border: 1px solid #ddd;
}

.btn-icon {
    padding: 10px;
    width: 38px;
    height: 38px;
}

.btn-view {
    background: var(--color-primary);
    color: #fff;
}

.btn-view:hover {
    background: var(--color-primary-dark);
}

.btn-outline:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
    text-decoration: none;
}

.btn-success {
    background: var(--color-success);
    color: #fff;
    border: 1px solid var(--color-success-dark);
}

.btn-success:hover {
    background: var(--color-success-dark);
}

.btn-form {
    width: 100%;
    margin-top: 12px;
    padding: 12px;
}

.items-inline {
    display: flex;
    align-items: center;
    gap: 12px;
}

.items-inline input {
    width: auto;
    flex: 1;
}

.items-inline .edit-icon {
    flex-shrink: 0;
}

.page-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.breadcrumbs {
    font-size: 13px;
    color: #8e8e8e;
    margin-bottom: 12px;
}

.breadcrumbs a {
    color: #8e8e8e;
    font-weight: 400;
}

.breadcrumbs a:hover {
    color: var(--color-primary);
    text-decoration: underline;
}

.breadcrumbs .crumb-current {
    color: #555;
    font-weight: 600;
}

.breadcrumbs .crumb-sep {
    margin: 0 6px;
    color: #ccc;
}

/* ===============================
   🔍 Toggle
================================ */
.toggle-container {
    position: relative;
    width: 220px;
    height: 60px;
    background-color: #fafaF6;
    border-radius: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10px;
}

.toggle-label {
    flex: 1;
    text-align: center;
    font-weight: bold;
    color: #666;
    z-index: 1;
}

.toggle-slider {
    position: absolute;
    top: 5px;
    left: 5px;
    width: 110px;
    height: 50px;
    background-color: #e9ecef;
    border-radius: 25px;
    transition: transform 0.3s;
}

.toggle-container.active .toggle-slider {
    transform: translateX(100px);
}

/* ===============================
   🪟 MODAL
================================ */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;

    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.modal.is-active {
    opacity: 1;
    pointer-events: auto;
}

.modal-box {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 24px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    animation: modalIn 0.2s ease;
}

@keyframes modalIn {
    from {
        transform: translateY(10px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-box h3 {
    margin: 0 0 16px;
    font-size: 18px;
    color: var(--color-text-main);
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 22px;
    line-height: 1;
    color: var(--color-text-muted);
    cursor: pointer;
}

.help-modal-box {
    position: relative;
    max-width: 640px;
    max-height: 80vh;
    overflow-y: auto;
}

.help-modal-content img {
    max-width: 100%;
}

.code-input {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 16px;
}

.code-input span {
    font-weight: 600;
    color: var(--color-text-muted);
}

.code-digit {
    width: 42px;
    height: 48px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
}

.code-digit:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(32, 176, 149, 0.2);
}

.join-loading {
    opacity: 0.6;
    pointer-events: none;
}

.join-success {
    color: var(--color-success);
}

.join-error {
    color: #e53e3e;
}

/* ===============================
   🏠 HOME PAGE
================================ */
.home-section {
    padding: 40px 0;
    scroll-margin-top: 20px;
}

.home-section p {
    color: var(--color-text-subtle);
}

.hero {
    padding: 64px 0;
    min-height: 420px;
    background-image: url('/hero.png');
    background-repeat: no-repeat;
    background-position: right center;
    background-size: contain;
}

.hero-inner {
    max-width: 640px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    background: #eafaf5;
    color: var(--color-primary-dark);
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 20px;
}

.hero h1 {
    font-size: 44px;
    line-height: 1.15;
    padding: 0;
    margin-bottom: 16px;
}

.hero-text {
    font-size: 17px;
    color: var(--color-text-subtle);
    margin-bottom: 24px;
    max-width: 520px;
}

.hero-checklist {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 8px;
}

.hero-checklist span {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--color-text-subtle);
    font-weight: 500;
}

.hero-checklist i {
    color: var(--color-primary);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.features-section {
    padding: 24px 0 56px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.feature-card {
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.feature-card .feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    background: #e6f9f3;
    color: var(--color-success);
}

.feature-card:nth-child(2) .feature-icon { background: #f1eafd; color: #7c3aed; }
.feature-card:nth-child(4) .feature-icon { background: #fff4e5; color: #c2740c; }
.feature-card:nth-child(5) .feature-icon { background: #eaf4fd; color: #1766a3; }
.feature-card:nth-child(6) .feature-icon { background: #f1eafd; color: #7c3aed; }

.feature-card h3 {
    font-size: 16px;
    color: var(--color-text-main);
    padding: 0;
}

.feature-card p {
    font-size: 14px;
    color: var(--color-text-subtle);
    margin: 0;
}

.stats-bar {
    background: var(--color-bg-muted);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 20px;
    text-align: center;
    margin: 40px 0 0;
}
#recurrenceFields {
    margin-top: 6px;
}

.stat-item .stat-number {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-primary);
}

.stat-item .stat-label {
    font-size: 14px;
    color: var(--color-text-subtle);
    margin-top: 4px;
}

.dna-exams-section {
    padding: 8px 0 64px;
}

.dna-exams-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.dna-emoji {
    font-size: 56px;
    margin-bottom: 12px;
}

.dna-eyebrow {
    font-size: 13px;
    font-weight: 700;
    color: var(--color-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.dna-block h2 {
    font-size: 28px;
    padding: 0;
    margin-bottom: 12px;
}

.dna-block h2 .accent {
    color: var(--color-primary);
}

.dna-text p {
    font-size: 15px;
    color: var(--color-text-subtle);
    margin-bottom: 8px;
}

.exams-block h2 {
    padding: 0;
    margin-bottom: 8px;
}

@media (max-width: 800px) {
    .dna-exams-grid {
        grid-template-columns: 1fr;
    }
    .hero h1 {
        font-size: 32px;
    }
    .hero {
        min-height: 0;
        background-image: none;
    }
}

.contact-form {
    max-width: 480px;
    margin-top: 16px;
}

/* ===============================
   📋 MEETING CARDS ("Mano susitikimai")
================================ */
.meeting-card {
    background: var(--color-bg-card);
    border: 1px solid #eee;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 20px 24px;
    margin-bottom: 16px;
}

.meeting-group-frame {
    border: 2px solid var(--color-primary);
    border-radius: var(--radius-lg);
    background: #f4fbf9;
    padding: 16px;
    margin-bottom: 24px;
}

.meeting-group-frame-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 15px;
}

.meeting-group-frame-header > i {
    color: var(--color-primary);
}

.meeting-group-frame-title {
    font-weight: 700;
    color: var(--color-text-main);
    margin-right: auto;
}

.meeting-group-frame .meeting-card {
    box-shadow: none;
}

.meeting-group-frame .meeting-card:last-child {
    margin-bottom: 0;
}

.meeting-card-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 14px;
}

.meeting-number {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: #eef2fb;
    color: var(--color-text-main);
    font-weight: 700;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.meeting-title {
    flex: 1;
    min-width: 160px;
    font-size: 19px;
    padding: 0;
    margin: 0;
}

.meeting-title a {
    color: var(--color-text-main);
    text-decoration: none;
}

.meeting-title a:hover {
    color: var(--color-primary-dark);
    text-decoration: underline;
}

.meeting-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
}

.status-pill-active {
    background: #e6f9f3;
    color: var(--color-success);
}

.status-pill-archived {
    background: var(--color-bg-muted);
    color: var(--color-muted);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    display: inline-block;
}

.meeting-meta-row {
    display: flex;
    flex-wrap: wrap;
    row-gap: 8px;
    column-gap: 22px;
    color: var(--color-text-subtle);
    font-size: 14px;
    margin-bottom: 14px;
}

.meeting-meta-item {
    display: flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
}

.meeting-meta-item i {
    color: var(--color-text-muted);
    width: 15px;
    text-align: center;
}

.meeting-link-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 14px;
    border-top: 1px solid #f0f0f0;
    color: var(--color-text-subtle);
    font-size: 14px;
}

.meeting-link-row > i {
    color: var(--color-text-muted);
}

.link-pill {
    background: var(--color-bg-muted);
    border-radius: 20px;
    padding: 6px 14px;
    font-family: monospace;
    font-size: 13px;
    color: var(--color-text-main);
    max-width: 320px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.copy-feedback {
    display: none;
    align-items: center;
    gap: 4px;
    color: var(--color-success);
    font-weight: 600;
    font-size: 13px;
}

.copy-feedback.is-visible {
    display: inline-flex;
}

@media (max-width: 480px) {
    .link-pill {
        max-width: 160px;
    }
}

/* ===============================
   🗓️ MEETING SLOT PICKER
================================ */
.slot-week-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 12px 0 8px;
}

.slot-grid-wrapper {
    overflow-x: auto;
    border: 1px solid #ddd;
    border-radius: var(--radius-lg);
    margin-bottom: 4px;
}

.slot-grid {
    display: grid;
    grid-template-columns: 64px repeat(7, minmax(84px, 1fr));
    width: max-content;
    min-width: 100%;
    user-select: none;
}

.slot-grid-corner {
    position: sticky;
    top: 0;
    left: 0;
    z-index: 3;
    background: var(--color-bg-muted);
    border-bottom: 1px solid #eee;
}

.slot-day-header {
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--color-bg-muted);
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-subtle);
    padding: 8px 4px;
    border-bottom: 1px solid #eee;
    border-left: 1px solid #eee;
}

.slot-day-header.today {
    color: var(--color-primary-dark);
}

.slot-time-label {
    position: sticky;
    left: 0;
    z-index: 1;
    background: #fff;
    font-size: 12px;
    color: var(--color-text-muted);
    padding: 4px 8px;
    text-align: right;
    border-top: 1px solid #f0f0f0;
}

label.slot-cell {
    min-height: 24px;
    border-top: 1px solid #f0f0f0;
    border-left: 1px solid #eee;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0;
    font-weight: 400;
    color: inherit;
}

.slot-cell-count {
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    pointer-events: none;
}

.slot-cell:hover {
    background: var(--color-bg-muted);
}

.slot-cell.selected {
    background: var(--color-primary);
}

.slot-cell.selected:hover {
    background: var(--color-primary-dark);
}

.slot-cell.past {
    background: #f5f5f5;
    cursor: not-allowed;
}

/* A slot that was marked while still in the future but has since passed - still counted
   and submitted, so it needs to read as distinctly "on" rather than blending into the
   plain (unselected) past cells above. */
.slot-cell.selected.past {
    background: #9e9e9e;
    cursor: pointer;
}

.slot-cell.locked {
    cursor: not-allowed;
}

.slot-cell-empty {
    background: transparent;
    cursor: default;
}

.book-slot-cell {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.book-slot-cell input {
    position: absolute;
    inset: 0;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}

.book-slot-count {
    font-size: 12px;
    font-weight: 600;
    color: var(--color-text-muted);
    pointer-events: none;
}

.book-slot-cell:has(input:checked) {
    background: var(--color-primary);
}

.book-slot-cell:has(input:checked) .book-slot-count {
    color: #fff;
}

.book-slot-cell:has(input:disabled) {
    background: #f5f5f5;
    cursor: not-allowed;
}

.book-slot-cell:has(input:disabled) .book-slot-count {
    color: #ccc;
}

/* ===============================
   🏡 PUBLIC LANDING PAGE (index.php, logged-out)
================================ */
.btn-lg {
    padding: 14px 26px;
    font-size: 15px;
    border-radius: 30px;
}

.landing-header {
    padding: 18px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
}

.landing-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.landing-nav {
    display: flex;
    align-items: center;
    gap: 28px;
}

.landing-nav a {
    color: var(--color-text-main);
    font-weight: 500;
    font-size: 15px;
    text-decoration: none;
}

.landing-nav a:hover {
    color: var(--color-primary-dark);
}

.landing-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.landing-hero {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-top: -20px;
    min-height: 700px;
    padding: 56px 0 72px;
    background: linear-gradient(180deg, #f6faf9 0%, #ffffff 100%);
    overflow: hidden;
    display: flex;
    align-items: center;
}

.landing-hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    align-items: center;
    gap: 48px;
    width: 100%;
}

.landing-hero-text h1 {
    font-size: 42px;
    line-height: 1.2;
    color: var(--color-text-main);
    padding: 0;
    margin-bottom: 20px;
}

.landing-hero-sub {
    font-size: 17px;
    color: var(--color-text-subtle);
    max-width: 520px;
    margin-bottom: 22px;
}

.landing-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 32px;
}

.landing-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    background: #ffffff;
    color: var(--color-text-main);
    font-size: 14px;
    font-weight: 500;
    box-shadow: var(--shadow-card);
}

.landing-badge i {
    color: var(--color-primary);
}

.landing-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.landing-hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.landing-hero-spacer {
    min-height: 1px;
}

.landing-ad-section {
    margin: 32px auto;
    max-width: 100%;
    overflow: hidden;
}

.landing-ad-section .adsbygoogle {
    max-width: 100%;
    margin: 0 auto;
}

.landing-steps-section {
    padding: 56px 0;
}

.landing-steps-section h2 {
    font-size: 28px;
    margin-bottom: 32px;
}

.landing-steps {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    flex-wrap: wrap;
}

.landing-step {
    flex: 1 1 200px;
    max-width: 240px;
}

.landing-step-icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 14px;
}

.landing-step-icon-blue {
    background: #eaf4fd;
    color: #1766a3;
}

.landing-step-icon-green {
    background: #e6f9f3;
    color: var(--color-success);
}

.landing-step h3 {
    font-size: 17px;
    padding: 0;
    margin-bottom: 6px;
}

.landing-step p {
    font-size: 14px;
    margin-bottom: 0;
}

.landing-step-arrow {
    align-self: center;
    color: var(--color-muted);
    font-size: 18px;
    margin-top: 20px;
}

.landing-bubble {
    flex: 1 1 220px;
    max-width: 260px;
    background: #eaf4fd;
    color: var(--color-text-main);
    font-weight: 600;
    font-size: 15px;
    padding: 20px;
    border-radius: 20px 20px 4px 20px;
    box-shadow: var(--shadow-card);
    transform: rotate(-2deg);
    align-self: flex-start;
    margin-top: 8px;
}

.landing-bubble i {
    color: #e0245e;
}

.testuok-promo {
    position: relative;
    background-size: cover;
    background-position: center right;
    background-repeat: no-repeat;
    background-color: #eafaf5;
    border-radius: var(--radius-lg);
    padding: 48px;
    margin-bottom: 56px;
    min-height: 340px;
    display: flex;
    align-items: center;
}

.testuok-promo-stretched-link {
    position: absolute;
    inset: 0;
}

.testuok-promo-content {
    position: relative;
    max-width: 480px;
}

.testuok-promo-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 24px;
    font-weight: 700;
    color: var(--color-text-main);
    margin-bottom: 20px;
}

.testuok-promo-logo i {
    color: var(--color-primary);
}

.testuok-promo-content h3 {
    font-size: 26px;
    line-height: 1.3;
    padding: 0;
    margin-bottom: 12px;
}

.testuok-promo-content p {
    font-size: 15px;
    margin-bottom: 24px;
}

.testuok-promo-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.testuok-promo-actions a:not(.btn) {
    font-weight: 600;
    color: var(--color-text-main);
}

.landing-footer {
    text-align: center;
    padding: 24px;
    color: var(--color-text-muted);
    font-size: 13px;
}

@media (max-width: 860px) {
    .landing-hero {
        display: block;
        min-height: 0;
        padding: 0 0 32px;
    }
    .landing-hero-image {
        position: static;
        width: 100%;
        height: 260px;
        margin-bottom: 24px;
    }
    .landing-hero-grid {
        grid-template-columns: 1fr;
    }
    .landing-hero-spacer {
        display: none;
    }
    .landing-hero-text h1 {
        font-size: 32px;
    }
    .landing-nav {
        display: none;
    }
    .landing-step-arrow {
        display: none;
    }
    .testuok-promo {
        background-image: none !important;
        min-height: 0;
        padding: 32px 24px;
    }
    .testuok-promo-content {
        max-width: none;
    }
}