/* ==========================================
   Листик
   home.css
========================================== */

.home-screen{
    min-height:100vh;
    width:100%;
    background:var(--color-bg);

    display:flex;
    justify-content:center;
    align-items:flex-start;

    padding:32px 24px;
}

.home-card{
    width:100%;
    max-width:1100px;

    display:flex;
    flex-direction:column;
    gap:28px;
}

/* ---------- HEADER ---------- */

.home-header{
    display:flex;
    justify-content:space-between;
    align-items:flex-start;
    gap:24px;
}

.brand-row{
    display:flex;
    align-items:center;
    gap:18px;
}

.brand-logo{
    width:58px;
    height:58px;
    flex-shrink:0;

    animation:leafFloat 2.2s ease;
    animation-iteration-count:1;
}

.brand-copy h1{
    margin:0;
    font-size:2rem;
    text-align:left;
}

.eyebrow{
    margin:0 0 6px;
    color:var(--color-text-light);
    font-size:1rem;
}

/* ---------- ACTIONS ---------- */

.action-grid{

    display:grid;

    grid-template-columns:2fr 1fr;

    gap:18px;

}

.action-card{

    border:none;

    border-radius:24px;

    padding:24px;

    background:white;

    transition:.2s;

    cursor:pointer;

}

.action-card:hover{

    transform:translateY(-2px);

}

.action-card.primary{

    background:linear-gradient(
        135deg,
        var(--color-primary),
        #63b06f
    );

    color:white;

}

/* ---------- RECENT ---------- */

.recent-list{

    display:flex;
    flex-direction:column;
    gap:14px;

}

.recent-item{

    background:white;

    border-radius:20px;

    padding:18px;

}

/* ---------- PHONE ---------- */

@media (max-width:768px){

    .home-screen{

        padding:20px 16px;

    }

    .home-header{

        flex-direction:column;

    }

    .action-grid{

        grid-template-columns:1fr;

    }

}
.action-side{

    display:flex;

    flex-direction:column;

    gap:18px;

}

.action-camera{

    min-height:210px;

}

.action-content{

    text-align:left;

}
.home-avatar{border-radius:50%;object-fit:cover}.home-quote{color:var(--color-text-light);font-size:.9rem;line-height:1.45;max-width:680px}.home-quote strong{color:var(--color-text)}.home-quote span{font-size:.78rem}.recent-item{cursor:pointer}.student-viewer{position:fixed;inset:0;background:#000;color:#fff;overflow:hidden;z-index:100}.student-media-stage{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:#000}.student-media{width:100%;height:100%;object-fit:contain}.student-drawing{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;pointer-events:none}.student-comment-overlay{position:absolute;z-index:8;left:0;right:0;bottom:0;padding:16px 18px calc(16px + env(safe-area-inset-bottom));background:#000000;color:#fff;line-height:1.4;text-shadow:none}.student-viewer-top{position:absolute;z-index:10;top:0;left:0;right:0;height:calc(70px + env(safe-area-inset-top));padding:18px;display:block;background:#000000}.student-viewer-top>div{position:absolute;top:18px;left:90px;right:90px;text-align:center;font-size:.9rem;color:#ffffff;text-shadow:none;pointer-events:none}.student-viewer-top span{display:block;font-size:.8rem;color:#ffffff;opacity:.75;margin-top:3px}.student-viewer-top button{position:absolute;top:18px;width:44px;height:44px;border:0;border-radius:50%;background:rgba(255,255,255,.14);color:#fff;font-size:24px;display:flex;align-items:center;justify-content:center;padding:0;line-height:1}.student-viewer-top button#studentViewerBack{left:18px}.student-viewer-top button#studentViewerClose{right:18px}.student-arrow{position:absolute;z-index:10;top:50%;width:42px;height:60px;border:0;border-radius:20px;background:rgba(0,0,0,.5);color:#fff;font-size:42px;transform:translateY(-50%)}.student-arrow.left{left:10px}.student-arrow.right{right:10px}
.recent-info{margin-left:0;padding-left:0}.recent-subject{padding-left:0;margin-left:0}

.home-quote-subject{font-size:.78rem;font-weight:800;color:var(--color-primary);margin-top:6px;margin-bottom:3px}.recent-subject{padding-left:0}.profile-logout{width:100%;padding:12px;border:0;border-radius:14px;background:#f2f3f2;color:#6b6f6b;font-weight:800;margin-top:10px}

.student-viewer,.student-media-stage,.student-media,.student-drawing{-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}.student-media{width:100vw!important;height:100dvh!important;max-width:none!important;max-height:none!important;object-fit:contain!important}.student-drawing{width:100vw!important;height:100dvh!important;max-width:none!important;max-height:none!important;object-fit:contain!important}.student-media-stage{width:100vw!important;height:100dvh!important}

.student-media,.student-drawing{pointer-events:none!important}

/* Профиль и аватар: сохраняем фотографию целиком. */
.home-avatar{object-fit:contain!important;background:#f2f4f2;overflow:hidden}
.recent-comments-note{margin-top:7px;color:var(--color-primary);font-size:.78rem;font-weight:700;line-height:1.3}
.recent-updated-note{margin-top:5px;color:#c8590c;font-size:.78rem;font-weight:700;line-height:1.3}
.student-comments-index{position:absolute;z-index:9;top:78px;left:50%;transform:translateX(-50%);padding:8px 12px;border-radius:14px;background:rgba(0,0,0,.5);color:#fff;font-size:13px;line-height:1.3;text-align:center;white-space:nowrap;max-width:calc(100vw - 40px);overflow:hidden;text-overflow:ellipsis}
.student-comment-overlay{bottom:24px;z-index:8}

/* Мобильная шапка: только на телефоне. Десктопная версия не меняется. */
.home-mobile-header{display:none}

@media (max-width:768px){
  .home-header{display:block;min-height:0;padding:0;margin-bottom:10px}
  .home-desktop-header{display:none}
  .home-mobile-header{display:block;width:100%}
  .home-mobile-top{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;width:100%}
  .home-mobile-greeting{display:flex;align-items:flex-start;gap:12px;min-width:0;flex:1 1 auto}
  .home-mobile-avatar{width:58px;height:58px;flex:0 0 58px;aspect-ratio:1/1;border-radius:50%;object-fit:cover;background:#f2f4f2;display:block}
  .home-mobile-greeting h1{margin:0;font-size:1.5rem;line-height:1.15;text-align:left;white-space:normal;overflow-wrap:break-word;min-width:0}
  .home-mobile-top .profile-icon-button{width:42px;height:42px;flex:0 0 42px}
  .home-mobile-top .profile-icon-button img{width:38px;height:38px}
  .home-mobile-quote{margin-top:12px;padding:0 2px}
  .home-mobile-quote .home-quote-subject{margin-top:0}
  .home-mobile-quote .home-quote{max-width:none;font-size:.9rem}
}
