:root {
    --page: #f8fbff;
    --panel: #ffffff;
    --ink: #0b2b68;
    --text: #20314f;
    --muted: #68758f;
    --blue: #1779e8;
    --blue-soft: #eaf6ff;
    --green: #36b86b;
    --green-soft: #edf9f2;
    --coral: #f16359;
    --coral-soft: #fff1ec;
    --mint: #52c9a3;
    --yellow: #ffc857;
    --purple: #7a66d9;
    --purple-soft: #f3efff;
    --orange-soft: #fff8e8;
    --line: #d7e2ef;
    --shadow: 0 18px 45px rgba(29, 64, 104, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    min-height: 100%;
    background: var(--page);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.45;
}

a {
    color: inherit;
}

button,
input {
    font: inherit;
}

.home-page {
    min-height: 100vh;
    overflow: auto;
    background: #f8fbff url("/assets/img/arkaplan.png") center center / cover no-repeat;
}

.tab-toggle {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.kids-app {
    min-height: 100vh;
}

.kids-header {
    height: 102px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px clamp(28px, 5vw, 70px);
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 6px 20px rgba(26, 64, 104, 0.08);
}

.kids-brand {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    color: var(--ink);
    text-decoration: none;
    font-size: clamp(24px, 2.1vw, 34px);
    font-weight: 900;
    letter-spacing: 0;
}

.logo-illustration {
    position: relative;
    width: 74px;
    height: 54px;
    display: inline-block;
}

.logo-illustration img,
.camera-spot img,
.paper-plane img,
.big-check img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.logo-book,
.logo-dome,
.logo-star {
    position: absolute;
    display: block;
}

.logo-book {
    left: 6px;
    bottom: 3px;
    width: 62px;
    height: 24px;
    border-radius: 6px 6px 16px 16px;
    background: linear-gradient(120deg, #41a6ee 0 47%, #2378dd 48% 100%);
    transform: skewX(-10deg);
}

.logo-dome {
    left: 25px;
    top: 5px;
    width: 28px;
    height: 32px;
    border-radius: 18px 18px 7px 7px;
    background: linear-gradient(180deg, #36bd80, #1b8f69);
}

.logo-dome::before {
    content: "";
    position: absolute;
    left: 12px;
    top: -10px;
    width: 8px;
    height: 14px;
    border: 3px solid #1b8f69;
    border-right: 0;
    border-bottom: 0;
    border-radius: 10px 0 0 0;
}

.logo-star {
    right: 2px;
    top: 8px;
    width: 17px;
    height: 17px;
    background: var(--yellow);
    clip-path: polygon(50% 0, 61% 34%, 98% 35%, 68% 56%, 79% 91%, 50% 70%, 21% 91%, 32% 56%, 2% 35%, 39% 34%);
}

.admin-link {
    display: inline-flex;
    min-height: 48px;
    align-items: center;
    gap: 10px;
    padding: 0 20px;
    border: 1px solid #99c9ff;
    border-radius: 8px;
    color: var(--blue);
    background: #fff;
    text-decoration: none;
    font-weight: 800;
    font-size: 18px;
}

.admin-link svg {
    width: 24px;
    height: 24px;
    fill: currentColor;
}

.kids-main {
    position: relative;
    width: min(100%, 1500px);
    height: 100vh;
    min-height: 690px;
    margin: 0 auto;
    padding: 18px clamp(26px, 4vw, 58px) 32px;
}

.kids-hero {
    position: relative;
    height: 118px;
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr) 90px;
    align-items: center;
    gap: 16px;
    text-align: center;
}

.kids-hero h1 {
    margin: 0 0 6px;
    color: var(--ink);
    font-size: clamp(34px, 3.1vw, 48px);
    line-height: 1;
    font-weight: 900;
    letter-spacing: 0;
    text-shadow: 0 3px 0 rgba(18, 71, 155, 0.08);
}

.kids-hero p {
    margin: 0;
    color: #53617d;
    font-size: clamp(17px, 1.25vw, 21px);
}

.camera-spot {
    width: 124px;
    height: 94px;
    justify-self: center;
    position: relative;
}

.camera-body {
    position: absolute;
    left: 18px;
    top: 32px;
    width: 108px;
    height: 70px;
    border-radius: 12px;
    background: linear-gradient(150deg, #318edf, #1e548d);
    box-shadow: 0 12px 18px rgba(23, 69, 115, 0.18);
}

.camera-body::before {
    content: "";
    position: absolute;
    left: 28px;
    top: -18px;
    width: 48px;
    height: 24px;
    border-radius: 10px 10px 0 0;
    background: #7dbff0;
}

.camera-body::after {
    content: "";
    position: absolute;
    right: 14px;
    top: 15px;
    width: 42px;
    height: 42px;
    border: 8px solid #123d6b;
    border-radius: 50%;
    background: radial-gradient(circle at 70% 25%, #fff 0 8%, #97d8ff 9% 22%, #246aa8 23% 100%);
}

.camera-body span {
    position: absolute;
    left: 14px;
    top: 18px;
    width: 22px;
    height: 10px;
    border-radius: 999px;
    background: #d9efff;
}

.heart-mark {
    width: 24px;
    height: 24px;
    align-self: end;
    justify-self: start;
    margin-bottom: 20px;
    transform: rotate(-45deg);
    background: var(--coral);
    border-radius: 7px;
}

.heart-mark::before,
.heart-mark::after {
    content: "";
    position: absolute;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--coral);
}

.heart-mark::before {
    top: -12px;
    left: 0;
}

.heart-mark::after {
    left: 12px;
    top: 0;
}

.decor {
    position: absolute;
    pointer-events: none;
}

.decor-cloud,
.decor-star,
.paper-plane {
    display: none;
}

.decor-cloud,
.success-cloud {
    width: 70px;
    height: 26px;
    border-radius: 999px;
    background: #dff1ff;
    filter: drop-shadow(0 4px 6px rgba(71, 144, 203, 0.1));
}

.decor-cloud::before,
.decor-cloud::after,
.success-cloud::before,
.success-cloud::after {
    content: "";
    position: absolute;
    bottom: 6px;
    border-radius: 50%;
    background: inherit;
}

.decor-cloud::before,
.success-cloud::before {
    left: 12px;
    width: 35px;
    height: 35px;
}

.decor-cloud::after,
.success-cloud::after {
    right: 8px;
    width: 27px;
    height: 27px;
}

.cloud-a {
    left: 42px;
    top: 44px;
}

.cloud-b {
    right: 38px;
    top: 54px;
}

.decor-star {
    width: 28px;
    height: 28px;
    background: var(--yellow);
    clip-path: polygon(50% 0, 61% 34%, 98% 35%, 68% 56%, 79% 91%, 50% 70%, 21% 91%, 32% 56%, 2% 35%, 39% 34%);
}

.star-a {
    left: 322px;
    top: 62px;
}

.star-b {
    right: 176px;
    top: 98px;
}

.paper-plane {
    right: 250px;
    top: 60px;
    width: 92px;
    height: 66px;
    background: linear-gradient(135deg, #ff907f, #f25b4d);
    clip-path: polygon(0 35%, 100% 0, 66% 88%, 43% 54%);
    transform: rotate(-12deg);
}

.paper-plane img {
    background: none;
    clip-path: none;
}

.paper-plane::after {
    content: "";
    position: absolute;
    left: -170px;
    top: 48px;
    width: 150px;
    height: 55px;
    border-top: 3px dashed #8bc3f4;
    border-radius: 50%;
}

.tab-card {
    position: relative;
    height: calc(100% - 118px);
    min-height: 500px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.tab-bar {
    height: 64px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-bottom: 1px solid var(--line);
    background: #fff;
}

.tab-label {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border-right: 1px solid var(--line);
    color: #5a5f66;
    cursor: pointer;
    font-size: clamp(16px, 1.15vw, 20px);
    font-weight: 900;
    user-select: none;
    white-space: nowrap;
}

.tab-label:last-child {
    border-right: 0;
}

.tab-label::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: transparent;
}

.tab-icon {
    position: relative;
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    border: 3px solid currentColor;
    border-radius: 50%;
}

.tab-icon.image-icon {
    width: 31px;
    height: 31px;
    border: 0;
    border-radius: 0;
    flex-basis: 31px;
}

.tab-icon.image-icon img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.video-icon {
    border-radius: 8px;
}

.video-icon::after {
    content: "";
    position: absolute;
    right: -13px;
    top: 9px;
    width: 14px;
    height: 16px;
    border: 3px solid currentColor;
    border-left: 0;
    border-radius: 0 7px 7px 0;
}

.question-icon::before {
    content: "?";
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 27px;
    font-weight: 900;
}

.upload-icon {
    border-radius: 12px;
    border-color: transparent;
}

.upload-icon::before {
    content: "";
    position: absolute;
    left: 4px;
    right: 4px;
    bottom: 6px;
    height: 22px;
    border: 3px solid currentColor;
    border-radius: 16px;
}

.upload-icon::after {
    content: "";
    position: absolute;
    left: 15px;
    top: 3px;
    width: 10px;
    height: 21px;
    background: currentColor;
    clip-path: polygon(50% 0, 100% 42%, 70% 42%, 70% 100%, 30% 100%, 30% 42%, 0 42%);
}

.check-icon::before {
    content: "";
    position: absolute;
    left: 9px;
    top: 8px;
    width: 18px;
    height: 11px;
    border-left: 4px solid currentColor;
    border-bottom: 4px solid currentColor;
    transform: rotate(-45deg);
}

#tab-guide:checked ~ .kids-app .guide-label,
#tab-questions:checked ~ .kids-app .questions-label,
#tab-upload:checked ~ .kids-app .upload-label {
    color: var(--blue);
    background: linear-gradient(180deg, #f6fbff, #e9f5ff);
}

#tab-upload:checked ~ .kids-app .upload-label {
    color: var(--coral);
}

#tab-guide:checked ~ .kids-app .guide-label::after,
#tab-questions:checked ~ .kids-app .questions-label::after,
#tab-upload:checked ~ .kids-app .upload-label::after {
    background: currentColor;
}

.tab-panels {
    position: relative;
    height: calc(100% - 64px);
}

.tab-panel {
    position: absolute;
    inset: 0;
    display: none;
    padding: 22px clamp(22px, 3vw, 48px) 34px;
}

#tab-guide:checked ~ .kids-app .guide-panel,
#tab-questions:checked ~ .kids-app .questions-panel,
#tab-upload:checked ~ .kids-app .upload-panel {
    display: block;
}

.big-check.has-image {
    border: 0;
    background: transparent;
}

.big-check.has-image::before,
.big-check.has-image::after {
    display: none;
}

.guide-panel,
.questions-panel,
.upload-panel {
    position: absolute;
}

.guide-panel {
    padding: 18px 24px 22px;
}

.success-card {
    display: grid;
}

.rules-board {
    height: 100%;
    display: grid;
    grid-template-rows: auto auto;
    align-content: start;
    gap: 12px;
}

.guide-intro {
    display: grid;
    justify-items: center;
    gap: 3px;
    border: 1px solid #cae2fa;
    border-radius: 10px;
    background: rgba(246, 251, 255, 0.92);
    color: #233556;
    padding: 13px 18px;
    text-align: center;
    font-size: 15px;
    font-weight: 800;
}

.guide-intro strong {
    color: var(--ink);
}

.guide-intro > * {
    min-width: 0;
    max-width: 100%;
}

.guide-intro .guide-lead {
    display: block;
    width: 100%;
    font-size: 19px;
    line-height: 1.18;
}

.guide-intro p {
    max-width: 1120px;
    margin: 0;
    color: #45546f;
    font-size: 16.5px;
    line-height: 1.34;
    font-weight: 800;
}

.rule-groups {
    min-height: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: min-content;
    align-content: start;
    gap: 14px;
}

.rule-group {
    min-height: 0;
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    margin: 0;
    padding: 10px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.92);
}

.rule-group-head {
    display: grid;
    gap: 6px;
    align-items: start;
    justify-items: center;
    text-align: center;
}

.rule-group-head img {
    display: block;
    width: 94px;
    height: 74px;
    object-fit: contain;
}

.rule-group h3 {
    margin: 0;
    color: var(--ink);
    font-size: 15.5px;
    line-height: 1.15;
    font-weight: 900;
}

.rule-theme-1 {
    border-color: #bfe2ff;
    background: rgba(240, 248, 255, 0.92);
}

.rule-theme-2 {
    border-color: #bce9ca;
    background: rgba(239, 250, 242, 0.92);
}

.rule-theme-3 {
    border-color: #ffdda0;
    background: rgba(255, 248, 232, 0.92);
}

.rule-theme-4 {
    border-color: #d9c9ff;
    background: rgba(246, 241, 255, 0.92);
}

.rule-list {
    display: grid;
    gap: 6px;
}

.rule-row {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 8px;
    align-items: start;
    border: 1px solid rgba(255, 255, 255, 0.74);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.72);
    padding: 7px 8px;
}

.rule-theme-1 .rule-row {
    box-shadow: inset 4px 0 0 rgba(23, 121, 232, 0.24);
}

.rule-theme-2 .rule-row {
    box-shadow: inset 4px 0 0 rgba(54, 184, 107, 0.24);
}

.rule-theme-3 .rule-row {
    box-shadow: inset 4px 0 0 rgba(244, 162, 27, 0.26);
}

.rule-theme-4 .rule-row {
    box-shadow: inset 4px 0 0 rgba(122, 102, 217, 0.24);
}

.rule-mark {
    position: relative;
    width: 17px;
    height: 17px;
    margin-top: 1px;
}

.rule-mark::after {
    content: "";
    position: absolute;
    left: 3px;
    top: 4px;
    width: 11px;
    height: 7px;
    border-left: 3px solid var(--green);
    border-bottom: 3px solid var(--green);
    transform: rotate(-45deg);
}

.rule-row strong {
    display: block;
    margin-bottom: 3px;
    color: #0d2d69;
    font-size: 17.5px;
    line-height: 1.18;
    font-weight: 900;
}

.rule-row p {
    margin: 0;
    color: #53617d;
    font-size: 14px;
    line-height: 1.28;
    font-weight: 700;
}

.rule-subnotes {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
}

.rule-subnotes li {
    border: 1px solid rgba(54, 184, 107, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.86);
    color: #36506c;
    padding: 4px 8px;
    font-size: 12.5px;
    line-height: 1.25;
    font-weight: 800;
}

#tab-guide:checked ~ .kids-app .tab-card {
    height: auto;
    overflow: visible;
}

#tab-guide:checked ~ .kids-app .tab-panels {
    height: auto;
}

#tab-guide:checked ~ .kids-app .guide-panel {
    position: static;
    inset: auto;
}

#tab-guide:checked ~ .kids-app .rules-board {
    height: auto;
}

.questions-panel {
    padding: 18px 24px 22px;
}

.questions-board {
    height: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.question-list {
    min-height: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.92);
}

.student-list {
    border-color: #bfe2ff;
    background: rgba(240, 248, 255, 0.94);
}

.parent-list {
    border-color: #bce9ca;
    background: rgba(239, 250, 242, 0.94);
}

.question-list-heading {
    display: grid;
    grid-template-columns: 82px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.question-heading-icons {
    display: flex;
    align-items: center;
    gap: 4px;
}

.question-heading-icons img {
    width: 38px;
    height: 38px;
    object-fit: contain;
}

.question-list h2 {
    margin: 0;
    color: var(--ink);
    font-size: 26px;
    line-height: 1.1;
    font-weight: 900;
}

.question-items {
    min-height: 0;
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
}

.question-item {
    display: grid;
    grid-template-columns: 32px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.78);
    color: #17305b;
    padding: 9px 10px;
    font-size: 18px;
    line-height: 1.25;
    font-weight: 800;
}

.question-item span {
    display: grid;
    width: 28px;
    height: 28px;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: var(--blue);
    font-size: 15px;
    font-weight: 900;
}

.parent-list .question-item span {
    background: var(--green);
}

.upload-panel-layout {
    height: 100%;
    display: block;
}

.kids-upload-form {
    height: auto;
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(360px, 1.15fr);
    grid-template-rows: auto auto;
    gap: 8px 18px;
    align-content: start;
}

.form-fields-panel,
.video-select-panel {
    min-height: 0;
    border: 1px solid transparent;
    border-radius: 14px;
    padding: 15px;
}

.form-fields-panel {
    display: grid;
    gap: 13px;
    align-content: start;
    border-color: #bfe2ff;
    background: rgba(240, 248, 255, 0.94);
}

.video-select-panel {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    gap: 12px;
    border-color: #f7b2ab;
    background: linear-gradient(180deg, rgba(255, 245, 242, 0.96), rgba(255, 255, 255, 0.96));
}

.upload-section-head {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--ink);
}

.upload-section-head strong,
.upload-section-head small {
    display: block;
}

.upload-section-head strong {
    font-size: 23px;
    line-height: 1.08;
    font-weight: 900;
}

.upload-section-head small {
    margin-top: 3px;
    color: #66728a;
    font-size: 14px;
    line-height: 1.2;
    font-weight: 800;
}

.section-badge {
    display: grid;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    font-size: 19px;
    font-weight: 900;
    box-shadow: inset 0 -3px 0 rgba(0, 0, 0, 0.12);
}

.blue-badge {
    background: var(--blue);
}

.coral-badge {
    background: var(--coral);
}

.form-row {
    display: grid;
    grid-template-columns: 38px minmax(92px, 0.36fr) minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.76);
    padding: 10px;
}

.form-row label {
    color: #17234a;
    font-size: 18px;
    font-weight: 900;
}

.form-row input[type="text"] {
    height: 44px;
    width: 100%;
    border: 1px solid #cfd9e6;
    border-radius: 8px;
    color: var(--text);
    background: #fff;
    padding: 0 16px;
    font-size: 18px;
}

.form-row input[type="text"]:focus {
    border-color: #7cbcff;
    outline: 3px solid rgba(23, 121, 232, 0.14);
}

.form-row input[type="text"].is-invalid {
    border-color: #f16359;
    background: #fff7f5;
    outline: 3px solid rgba(241, 99, 89, 0.14);
}

.form-warning {
    border: 1px solid rgba(241, 99, 89, 0.28);
    border-radius: 10px;
    background: #fff1ec;
    color: #a6372f;
    padding: 10px 12px;
    font-size: 15px;
    line-height: 1.25;
    font-weight: 900;
}

.form-warning[hidden] {
    display: none;
}

.field-icon {
    position: relative;
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    justify-self: center;
}

.person-blue::before,
.person-green::before {
    content: "";
    position: absolute;
    top: 2px;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: var(--blue);
}

.person-blue::after,
.person-green::after {
    content: "";
    position: absolute;
    bottom: 2px;
    width: 30px;
    height: 16px;
    border-radius: 16px 16px 5px 5px;
    background: var(--blue);
}

.person-green::before,
.person-green::after {
    background: var(--green);
}

.pencil-orange::before {
    content: "";
    width: 29px;
    height: 10px;
    border-radius: 3px;
    background: #f4a21b;
    transform: rotate(-45deg);
}

.pencil-orange::after {
    content: "";
    position: absolute;
    right: 1px;
    top: 8px;
    border-left: 8px solid #344054;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
    transform: rotate(-45deg);
}

.drop-zone {
    position: relative;
    min-height: 330px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 9px;
    border: 2px dashed #ec756b;
    border-radius: 18px;
    background: linear-gradient(180deg, #fffefe, #fff6f3);
    color: #17234a;
    text-align: center;
    overflow: hidden;
    padding: 18px;
    cursor: pointer;
    box-shadow: 0 14px 28px rgba(241, 99, 89, 0.12);
}

.drop-zone input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.drop-zone.is-uploading input[type="file"] {
    pointer-events: none;
}

.drop-zone.has-file {
    border-color: var(--green);
    background: linear-gradient(180deg, #fbfffd, #effbf4);
    box-shadow: 0 14px 28px rgba(54, 184, 107, 0.14);
}

.drop-zone.is-uploading {
    border-color: var(--blue);
    background: linear-gradient(180deg, #f7fbff, #eaf6ff);
    cursor: wait;
    box-shadow: 0 14px 28px rgba(23, 121, 232, 0.15);
}

.selected-file {
    display: block;
    width: min(100%, 460px);
    border: 1px solid rgba(54, 184, 107, 0.28);
    border-radius: 10px;
    background: rgba(237, 249, 242, 0.96);
    color: #16643d;
    padding: 9px 11px;
    font-size: 14px;
    line-height: 1.25;
    font-weight: 900;
    overflow-wrap: anywhere;
}

.selected-file[hidden] {
    display: none;
}

.selected-file.is-warning {
    border-color: rgba(241, 99, 89, 0.38);
    background: rgba(255, 241, 236, 0.96);
    color: #a6372f;
}

.drop-art {
    display: block;
    width: min(100%, 360px);
    max-height: 188px;
    object-fit: contain;
}

.drop-zone strong {
    color: #17234a;
    font-size: 26px;
    line-height: 1.05;
    font-weight: 900;
}

.drop-helper {
    max-width: 440px;
    color: #55617a;
    font-size: 15px;
    line-height: 1.25;
    font-weight: 800;
}

.drop-zone small {
    color: var(--muted);
    font-size: 12.5px;
    line-height: 1.3;
    font-weight: 700;
}

.file-button {
    position: relative;
    z-index: 1;
    display: inline-grid;
    min-width: 190px;
    min-height: 48px;
    place-items: center;
    border: 0;
    border-radius: 10px;
    color: #fff;
    background: linear-gradient(180deg, #8b78ef, var(--purple));
    box-shadow: 0 5px 0 #5f4bbc, 0 12px 22px rgba(122, 102, 217, 0.22);
    font-size: 20px;
    font-weight: 900;
}

.drop-zone.has-file .file-button {
    background: linear-gradient(180deg, #43c878, var(--green));
    box-shadow: 0 5px 0 #249153, 0 12px 22px rgba(54, 184, 107, 0.22);
}

.drop-zone.is-uploading .file-button {
    background: linear-gradient(180deg, #56a8ff, var(--blue));
    box-shadow: 0 5px 0 #1260bb, 0 12px 22px rgba(23, 121, 232, 0.22);
}

.drop-zone.is-uploading .drop-art {
    opacity: 0.72;
}

.upload-progress {
    position: relative;
    z-index: 1;
    display: grid;
    width: min(100%, 440px);
    gap: 8px;
    border: 1px solid rgba(23, 121, 232, 0.16);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.82);
    padding: 11px;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.4);
}

.upload-progress[hidden] {
    display: none;
}

.upload-progress-track {
    height: 15px;
    overflow: hidden;
    border-radius: 999px;
    background: #d8ebff;
    box-shadow: inset 0 1px 3px rgba(23, 49, 86, 0.12);
}

.upload-progress-bar {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #1779e8, #36b86b);
    transition: width 0.18s ease;
}

.upload-progress-label {
    color: #135fb4;
    font-size: 14px;
    line-height: 1.25;
    font-weight: 900;
}

.upload-progress.is-indeterminate .upload-progress-bar {
    width: 42%;
    animation: upload-progress-slide 1.1s ease-in-out infinite;
}

@keyframes upload-progress-slide {
    0% {
        transform: translateX(-120%);
    }

    50% {
        transform: translateX(50%);
    }

    100% {
        transform: translateX(240%);
    }
}

.upload-bottom {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
    justify-items: stretch;
    gap: 0;
    margin-top: 0;
    width: 100%;
}

.send-button {
    min-height: 66px;
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(180deg, #ff746b, var(--coral));
    box-shadow: 0 5px 0 #d84a41, 0 10px 20px rgba(241, 99, 89, 0.24);
    cursor: pointer;
    font-size: clamp(20px, 1.7vw, 28px);
    font-weight: 900;
}

.send-button strong {
    font: inherit;
}

.send-button:disabled {
    cursor: wait;
    opacity: 0.78;
    box-shadow: 0 5px 0 #b94139, 0 10px 20px rgba(241, 99, 89, 0.16);
}

.send-button span {
    width: 34px;
    height: 22px;
    border-radius: 999px;
    background: #fff;
    position: relative;
}

.send-button span::before {
    content: "";
    position: absolute;
    left: 9px;
    top: -12px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: #fff;
}

.send-button span::after {
    content: "";
    position: absolute;
    left: 11px;
    top: -9px;
    width: 12px;
    height: 27px;
    background: var(--coral);
    clip-path: polygon(50% 0, 100% 38%, 70% 38%, 70% 100%, 30% 100%, 30% 38%, 0 38%);
}

.notice {
    grid-column: 1 / -1;
    border-radius: 10px;
    padding: 13px 16px;
    font-weight: 800;
}

.notice.success {
    background: rgba(54, 184, 107, 0.12);
    color: #0f7a45;
}

.notice.error {
    background: rgba(241, 99, 89, 0.12);
    color: #ba362f;
}

.trap {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.success-state {
    position: relative;
    height: 100%;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 12px;
    padding: 34px 24px 120px;
    text-align: center;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 34%, rgba(82, 201, 163, 0.16), transparent 28%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(249, 255, 252, 0.96));
}

.success-complete {
    min-height: 100%;
}

.big-check {
    position: relative;
    width: 168px;
    height: 168px;
    border-radius: 50%;
    border: 5px solid #69caa4;
    background: #e9fbf3;
}

.big-check::after {
    content: "";
    position: absolute;
    left: 47px;
    top: 48px;
    width: 77px;
    height: 43px;
    border-left: 20px solid #0cc488;
    border-bottom: 20px solid #0cc488;
    border-radius: 4px;
    transform: rotate(-45deg);
}

.success-kicker {
    display: inline-grid;
    min-height: 34px;
    place-items: center;
    border: 1px solid #94ddbf;
    border-radius: 999px;
    background: #eefbf5;
    color: #087640;
    padding: 0 18px;
    font-size: 15px;
    font-weight: 900;
}

.success-state h2 {
    margin: 0;
    color: #087640;
    font-size: clamp(40px, 4vw, 58px);
    line-height: 1;
    font-weight: 900;
    letter-spacing: 0;
}

.success-state p {
    margin: 0;
    color: #61708b;
    font-size: 24px;
    font-weight: 700;
}

.success-hill {
    position: absolute;
    bottom: 0;
    width: min(30%, 360px);
    height: auto;
    pointer-events: none;
}

.success-hill.left {
    left: 6%;
}

.success-hill.right {
    right: 6%;
}

.success-cloud {
    position: absolute;
}

.cloud-left {
    left: 14%;
    top: 28%;
}

.cloud-right {
    right: 14%;
    top: 30%;
}

/* Admin */
.admin-page {
    min-height: 100vh;
    background: #f6f8fb;
}

.admin-page .site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px clamp(20px, 5vw, 72px);
    background: #fff;
    border-bottom: 1px solid var(--line);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--ink);
    font-size: 18px;
    font-weight: 900;
    text-decoration: none;
}

.brand-mark {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 50%;
    background: var(--blue);
    color: #fff;
    font-size: 14px;
}

.top-nav {
    display: flex;
    align-items: center;
    gap: 16px;
    color: var(--muted);
    font-size: 15px;
}

.top-nav a,
.nav-button,
.primary-button,
.secondary-button,
.danger-button {
    text-decoration: none;
}

.nav-button,
.primary-button,
.secondary-button,
.danger-button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-weight: 800;
}

.primary-button,
.secondary-button,
.danger-button {
    cursor: pointer;
}

.nav-button,
.primary-button {
    padding: 0 18px;
    border: 0;
    background: var(--blue);
    color: #fff;
}

.secondary-button {
    padding: 0 16px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--blue);
}

.danger-button {
    padding: 0 16px;
    border: 1px solid #f2b4ad;
    background: #fff4f2;
    color: #b4332d;
    font: inherit;
}

.full {
    width: 100%;
}

.admin-main {
    padding: clamp(32px, 6vw, 72px) clamp(20px, 5vw, 72px);
}

.login-panel,
.admin-heading,
.empty-state {
    max-width: 520px;
    margin: 0 auto;
}

.login-panel,
.empty-state,
.submission-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(31, 45, 47, 0.07);
}

.login-panel,
.empty-state {
    padding: 28px;
}

.admin-heading {
    max-width: 1180px;
    margin-bottom: 26px;
}

.admin-heading h1,
.login-panel h1 {
    margin: 0 0 10px;
    color: var(--ink);
}

.upload-form {
    display: grid;
    gap: 18px;
    margin-top: 22px;
}

.upload-form label {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 800;
}

.upload-form input {
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 0 14px;
}

.admin-notice,
.admin-tools {
    max-width: 1180px;
    margin: 0 auto 18px;
}

.admin-search {
    display: grid;
    grid-template-columns: minmax(160px, 1fr) auto auto;
    align-items: end;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    padding: 14px;
    box-shadow: 0 10px 30px rgba(31, 45, 47, 0.06);
}

.admin-search label {
    grid-column: 1 / -1;
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
}

.admin-search input {
    min-height: 44px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--text);
    padding: 0 14px;
    font-size: 16px;
}

.submission-list {
    display: grid;
    max-width: 1180px;
    margin: 0 auto;
    gap: 20px;
}

.submission-card {
    display: grid;
    grid-template-columns: minmax(260px, 420px) minmax(0, 1fr);
    gap: 24px;
    padding: 18px;
}

.video-frame {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    background: #0b1d36;
    aspect-ratio: 16 / 9;
}

.video-frame video {
    display: block;
    width: 100%;
    height: 100%;
    opacity: 0;
    background: #050b14;
    object-fit: contain;
    transition: opacity 0.18s ease;
}

.submission-card.is-video-ready .video-frame video {
    opacity: 1;
}

.video-load-button {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    width: 100%;
    border: 0;
    background: #102d54;
    color: #fff;
    padding: 22px;
    text-align: left;
    cursor: pointer;
}

.video-load-button:hover {
    background: #16406f;
}

.video-load-button:focus-visible {
    outline: 3px solid #78b7ff;
    outline-offset: -4px;
}

.video-load-button[hidden] {
    display: none;
}

.video-load-button.is-loading {
    cursor: wait;
}

.video-load-button > span:last-child {
    display: grid;
    gap: 4px;
}

.video-load-button strong {
    font-size: 20px;
}

.video-load-button small {
    color: #c8dcf4;
    font-size: 13px;
    font-weight: 700;
}

.video-load-icon {
    position: relative;
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    border-radius: 50%;
    background: #fff;
}

.video-load-icon::after {
    content: '';
    position: absolute;
    left: 21px;
    top: 15px;
    border-top: 11px solid transparent;
    border-bottom: 11px solid transparent;
    border-left: 17px solid #1779e8;
}

.video-load-button.is-loading .video-load-icon::after {
    left: 16px;
    top: 16px;
    width: 16px;
    height: 16px;
    border: 4px solid #cfe5ff;
    border-top-color: #1779e8;
    border-radius: 50%;
    animation: video-loader-spin 0.8s linear infinite;
}

@keyframes video-loader-spin {
    to {
        transform: rotate(360deg);
    }
}

.video-load-status {
    position: absolute;
    z-index: 2;
    right: 10px;
    bottom: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: #24405f;
    padding: 6px 10px;
    font-size: 12px;
    line-height: 1;
    font-weight: 900;
    pointer-events: none;
}

.video-load-status[data-state="loading"] {
    color: #135fb4;
}

.video-load-status[data-state="ready"],
.video-load-status[data-state="playing"] {
    color: #11713f;
}

.video-load-status[data-state="error"] {
    color: #b4332d;
}

.admin-load-more {
    display: grid;
    justify-items: center;
    max-width: 1180px;
    margin: 24px auto 0;
    gap: 10px;
}

.admin-load-more p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    font-weight: 800;
}

.admin-load-more-button {
    min-width: 220px;
    justify-content: center;
}

.admin-load-more-button.is-loading {
    opacity: 0.7;
    pointer-events: none;
}

.admin-all-loaded,
.admin-load-more-feedback {
    min-height: 18px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

.admin-load-more-feedback:not(:empty) {
    color: #135fb4;
}

.submission-title {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 16px;
}

.submission-title h2 {
    margin: 0 0 16px;
    color: var(--ink);
    font-size: 28px;
}

.submission-title span {
    color: var(--muted);
    font-weight: 800;
}

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.admin-actions form {
    margin: 0;
}

dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 0 0 18px;
}

dt {
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

dd {
    margin: 2px 0 0;
}

@media (max-height: 820px) and (min-width: 1101px) {
    .home-page {
        overflow: auto;
    }

    .kids-main {
        height: auto;
        min-height: 100vh;
    }

    .tab-card {
        height: auto;
        min-height: 0;
        overflow: visible;
    }

    .tab-panels {
        height: auto;
    }

    .tab-panel,
    .guide-panel,
    .questions-panel,
    .upload-panel {
        position: static;
        inset: auto;
    }

    .rules-board,
    .questions-board,
    .upload-panel-layout,
    .success-state {
        height: auto;
    }
}

@media (max-width: 1100px) {
    .home-page {
        overflow: auto;
    }

    .kids-main {
        height: auto;
        min-height: 100vh;
    }

    .kids-hero {
        grid-template-columns: 120px minmax(0, 1fr);
        height: auto;
        min-height: 150px;
    }

    .heart-mark {
        display: none;
    }

    .tab-card {
        height: auto;
        min-height: 0;
        overflow: visible;
    }

    .tab-panels {
        height: auto;
    }

    .tab-panel {
        padding: 12px;
    }

    .tab-panel,
    .guide-panel,
    .questions-panel,
    .upload-panel {
        position: static;
        inset: auto;
    }

    .kids-upload-form,
    .upload-bottom {
        grid-template-columns: 1fr;
    }

    .tab-panel {
        padding: 18px;
    }

    .rules-board,
    .questions-board,
    .upload-panel-layout,
    .success-state {
        height: auto;
    }

    .upload-panel-layout {
        align-items: start;
    }
}

@media (max-width: 760px) {
    .kids-header,
    .admin-page .site-header {
        height: auto;
        align-items: flex-start;
        flex-direction: column;
    }

    .kids-main {
        padding: 12px;
    }

    .kids-hero {
        grid-template-columns: 1fr;
        min-height: 102px;
        text-align: center;
    }

    .kids-hero h1 {
        font-size: 30px;
        line-height: 1.05;
    }

    .kids-hero p {
        font-size: 16px;
    }

    .camera-spot,
    .decor,
    .paper-plane {
        display: none;
    }

    .tab-bar {
        height: auto;
        grid-template-columns: repeat(3, 1fr);
    }

    .tab-label {
        min-height: 58px;
        gap: 5px;
        padding: 7px 4px;
        font-size: 12.5px;
        white-space: normal;
        text-align: center;
        line-height: 1.1;
    }

    .tab-icon.image-icon {
        width: 24px;
        height: 24px;
        flex-basis: 24px;
    }

    .tab-card {
        min-height: 0;
        border-radius: 12px;
    }

    .tab-panels {
        height: auto;
    }

    .rule-groups,
    .questions-board,
    .admin-search,
    .submission-card,
    dl {
        grid-template-columns: 1fr;
    }

    .guide-intro {
        align-items: stretch;
        gap: 3px;
        padding: 11px 12px;
    }

    .guide-intro .guide-lead {
        font-size: 17.5px;
        line-height: 1.18;
    }

    .guide-intro p {
        font-size: 15.5px;
        line-height: 1.34;
    }

    .rule-group {
        grid-template-columns: 82px minmax(0, 1fr);
        gap: 8px;
        padding: 9px;
    }

    .rule-group-head img {
        width: 70px;
        height: 58px;
    }

    .rule-group h3 {
        font-size: 13.5px;
    }

    .rule-row {
        padding: 7px;
    }

    .rule-row strong {
        font-size: 17.5px;
    }

    .rule-row p {
        font-size: 14px;
    }

    .question-list {
        padding: 12px;
    }

    .question-list-heading {
        grid-template-columns: 66px minmax(0, 1fr);
        gap: 8px;
    }

    .question-heading-icons img {
        width: 31px;
        height: 31px;
    }

    .question-list h2 {
        font-size: 22px;
    }

    .question-item {
        grid-template-columns: 29px minmax(0, 1fr);
        padding: 9px;
        font-size: 17px;
        line-height: 1.25;
    }

    .question-item span {
        width: 26px;
        height: 26px;
        font-size: 14px;
    }

    .kids-upload-form {
        height: auto;
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .video-select-panel {
        order: 1;
    }

    .form-fields-panel {
        order: 2;
    }

    .upload-bottom {
        order: 3;
    }

    .form-fields-panel,
    .video-select-panel {
        padding: 12px;
    }

    .upload-section-head strong {
        font-size: 20px;
    }

    .upload-section-head small {
        font-size: 13px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 7px;
        padding: 9px;
    }

    .form-row label {
        font-size: 16px;
    }

    .field-icon {
        display: none;
    }

    .drop-zone {
        min-height: 270px;
        padding: 14px 10px;
    }

    .drop-art {
        width: min(100%, 300px);
        max-height: 142px;
    }

    .drop-zone strong {
        font-size: 21px;
    }

    .drop-zone small {
        font-size: 12px;
    }

    .drop-helper {
        font-size: 13px;
    }

    .file-button {
        min-width: 168px;
        min-height: 44px;
        font-size: 18px;
    }

    .send-button {
        min-height: 58px;
        font-size: 18px;
    }

    .success-state {
        min-height: 440px;
        padding: 30px 16px 100px;
    }

    .big-check {
        width: 132px;
        height: 132px;
    }

    .big-check::after {
        left: 35px;
        top: 36px;
        width: 56px;
        height: 32px;
        border-left-width: 15px;
        border-bottom-width: 15px;
    }

    .success-state h2 {
        font-size: 32px;
    }

    .success-state p {
        font-size: 18px;
    }

}
