* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Оптимизация загрузки изображений */
img {
    image-rendering: auto;  /* по умолчанию хорошее качество */
}

/* Только для растровых изображений (PNG, JPG) */
img[src$=".png"],
img[src$=".jpg"],
img[src$=".jpeg"],
img[src$=".webp"] {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

html,body { 
    height: 100%;
}

body {
    font-family: 'SantaMaria', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: white;

    display: flex;
    flex-direction: column;
}

body.auth-pending .account-section {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}

.account-auth-loading {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 18px;
    color: #282828;
    z-index: 999;
}
body.auth-pending .account-auth-loading {
    display: block;
}

/* HEADER */
.top-block {
    width: 350px;
    height: 50px;
    position: fixed;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    /* liquid glass */
    background: rgba(32, 32, 32, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);

    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 20px;
    gap: 50px;

    border-radius: 100px;

    margin: 0;  
    margin-bottom: 0;
}

.top-block button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.top-block button img {
    display: block;
}

.top-block button,
.top-block a.btn-home {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.btn-home img,
.btn-menu img {
    width: 20px;
    height: 20px;
    user-select: none;
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    transition: opacity 0.2s ease;
}

.nav-news,
.nav-products {
    font-size: 16px;
    color: #3E3E3E;
    margin: 0;
    transition: color 0.2s ease;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: inline-block;      
    text-decoration: none;
}

.nav-news:hover,
.nav-products:hover {
    color: white;
}

.btn-menu img {
    width: 31px;
    height: 31px;
}

.btn-home .icon-hover,
.btn-menu .icon-hover {
    display: none;
}

.btn-home .icon-normal,
.btn-menu .icon-normal {
    display: block;
}

.btn-home:hover .icon-normal,
.btn-menu:hover .icon-normal {
    display: none;
}

.btn-home:hover .icon-hover,
.btn-menu:hover .icon-hover {
    display: block;
}

.menu-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-dropdown {
    position: fixed;
    top: 70px;
    left: 50%;
    transform: translateX(-50%) translateZ(0);
    width: 350px;
    height: 194px;
    z-index: 1001;

    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;

    background: rgba(32, 32, 32, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
    border-radius: 20px;

    isolation: isolate;
}

.menu-dropdown.menu-dropdown-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.menu-dropdown-link {
    display: block;
    padding: 12px 16px;
    font-size: 32px;
    font-weight: 500;
    color: #373737;
    text-decoration: none;
    border-radius: 12px;
    transition: background 0.2s ease, color 0.2s ease;
}

.menu-dropdown-link:hover {
    color: black;
}

.menu-dropdown::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    height: 15px;
}

/* END HEADER */

/* MAIN CONTENT */
/* Account Section */
.account-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 100px 20px 60px;
    margin: 0 auto;
}

/* Avatar */
.label-account-wrapper {
    margin: 50px 0 76px 0;
}

.label-account {
    max-width: 100px;
    max-height: 100px;
    width: 100%;
    height: 100%;
    display: block;
}

.avatar-account-wrapper {
    margin: 0 0 20px 0;
}

.avatar-account {
    max-width: 150px;
    max-height: 150px;
    width: 100%;
    height: 100%;
    display: block;
    background: black;
    border-radius: 100px;
}

.account-section .account-fullname {
    font-size: 48px;
    color: black;
    font-weight: bold;
    margin: 0 0 20px 0;
}

.account-section .account-email {
    font-size: 48px;
    color: #4c4c4c;
    font-weight: 300;
    margin: 0 0 20px 0;
}

.btn-subscribe {
    width: 230px;
    height: 63px;
    margin: 0 0 20px 0;
    font-size: 36px;
    color: #6A6A6A;
    background: transparent;
    border: 2px solid #6A6A6A;
    border-radius: 100px;
    cursor: normal;
    transition: background 0.3s ease, transform 0.2s ease;
    font-weight: normal;
}

.btn-settings {
    width: 200px;
    height: 60px;
    margin: 0 0 30px 0;
    font-size: 34px;
    color: white;
    background: #282828;
    border: none;
    border-radius: 100px;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
    font-weight: normal;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-settings-icon {
    display: block;
    width: 25px;
    height: 25px;
    object-fit: contain;
    flex-shrink: 0;
}

.btn-settings:hover {
    background: #414141;
    transform: scale(1.05);
}

.btn-settings:active {
    transform: scale(0.95);
}

.btn-exit {
    width: 150px;
    height: 50px;
    font-size: 34px;
    color: #370B0B;
    background: #E44E4E;
    border: none;
    border-radius: 100px;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
    font-weight: normal;
}

.btn-exit:hover {
    background: #EE5858;
    transform: scale(1.05);
}

.btn-exit:active {
    transform: scale(0.95);
}

/* END MAIN CONTENT */

/* === BASEMENT === */
.footer-basement {
  background: #ffffff;
  padding: 40px 20px;
  width: 100%;

  margin-top: 0;
  margin-bottom: 10px;
}

.basement {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

/* === Разделитель === */
.separator {
  width: 100%;
  max-width: 90%;
  height: 1px;
  background-color: #d2d2d7; /* Apple-style светло-серый */
}

/* === Нижняя часть === */
.basement-footer {
  width: 100%;
  max-width: 90%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

/* === Копирайт === */
.title-copyright {
  font-size: 12px;
  color: #86868b; /* Apple-style серый */
  font-weight: 300; /* Light начертание */
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  margin: 0;
  line-height: 1.5;
}

/* === Страна/Регион === */
.title-country {
  font-size: 12px;
  color: #86868b;
  font-weight: 300;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  margin: 0;
  line-height: 1.5;
}

/* === Ссылки (если будут) === */
.basement-footer a {
  color: #515154;
  text-decoration: none;
  transition: color 0.2s ease;
}

.basement-footer a:hover {
  color: #0071e3;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Mobile adaptation */

/* Tablet - 768px */
@media (max-width: 768px) {
    /* Header */
    .top-block {
        width: 100%;
        max-width: 350px;
        height: 50px;
        gap: 50px;
        padding: 0 15px;
    }

    .nav-news,
    .nav-products {
        font-size: 14px;
    }

    /* Hero Section */
    .hero-section {
        padding: 120px 20px 20px;
    }

    .logotype {
        width: 80px;
        margin-bottom: 24px;
    }

    .company-name {
        font-size: 72px;
    }

    .separator-main {
        width: 90%;
    }

    /* Content */
    .content-wrapper {
        padding: 0 20px;
    }

    .section-title {
        font-size: 24px;
    }

    .about-description {
        font-size: 22px;
    }

    .mission-label {
        font-size: 22px;
    }

    .mission-text {
        font-size: 22px;
    }

    .ceo-avatar {
        width: 48px;
        height: 59px;
    }

    .ceo-name {
        font-size: 24px;
    }

    .contact-label,
    .contact-email {
        font-size: 22px;
    }

    /* Basement */
    .separator {
        width: 90%;
    }

    .basement-footer {
        width: 90%;
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

/* Mobile - 480px */
@media (max-width: 480px) {
    /* Header */
    .top-block {
        width: 100%;
        max-width: 350px;
        height: 50px;
        gap: 50px;
        padding: 0 10px;
    }

    .nav-news,
    .nav-products {
        font-size: 14px;
    }

    .btn-home img {
        width: 20px;
        height: 20px;
    }

    .btn-menu img {
        width: 31px;
        height: 31px;
    }

    /* account Section */
    .account-section {
        padding: 120px 15px 100px;
        max-width: 90%;
    }

    .account-avatar {
        width: 114px;        
        height: 153px;
    }

    .account-title {
        font-size: 66px;       
        margin-bottom: 40px;
    }

    /* Form */
    .account-form {
        gap: 30px;             
    }

    .form-input {
        font-size: 24px;       
        padding: 6px 0;
    }

    .form-label {
        font-size: 24px;       
    }

    .form-input:focus + .form-label,
    .form-input:not(:placeholder-shown) + .form-label {
        top: -22px;
        font-size: 16px;       
    }

    .send-button {
        width: 140px;         
        height: 45px;          
        font-size: 20px;       
        margin-top: 15px;
        font-weight: normal;
    }

    /* BASEMENT */
    .basement {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
        position: relative;
        margin-bottom: 0;
    }

    .separator {
        width: 400px;
        height: 1px;
        background-color: #282828;
        margin-top: 0px;
    }

    .basement-footer {
        width: 400px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        flex-direction: column;
    }

    .title-copyright {
        font-size: 16px;
        color: #282828;
        margin: 0;
    }

    .title-country {
        font-size: 16px;
        color: #282828;
        margin: 0;
        margin-top: 10px;
    }
}

/* Small Mobile - 360px */
@media (max-width: 360px) {

    /* Header */
    .top-block {
        width: 100%;
        max-width: 350px;
        height: 50px;
        gap: 50px;
        padding: 0 8px;
    }

    .nav-news,
    .nav-products {
        font-size: 14px;
    }

    .btn-home img {
        width: 20px;
        height: 20px;
    }

    .btn-menu img {
        width: 31px;
        height: 31px;
    }

    /* account Section */
    .account-section {
        padding: 124px 10px 100px;
        max-width: 95%;
    }

    .account-avatar {
        width: 96px;        
        height: 127px;        
    }

    .account-title {
        font-size: 55px;       
        margin-bottom: 30px;
    }

    /* Form */
    .account-form {
        gap: 25px;             
    }

    .form-input {
        font-size: 20px;      
        padding: 5px 0;
    }

    .form-label {
        font-size: 20px;      
    }

    .form-input:focus + .form-label,
    .form-input:not(:placeholder-shown) + .form-label {
        top: -20px;
        font-size: 14px;      
    }

    .send-button {
        width: 125px;         
        height: 38px;         
        font-size: 20px;       
        margin-top: 12px;
        font-weight: normal;
    }

    /* BASEMENT */
    .basement {
        width: 300px;
        margin: 0 auto;         
        display: flex;
        flex-direction: column;
        align-items: center;
        position: relative;
        margin-top: 100px;
    }

    .separator {
        width: 300px;
        height: 1px;
        background-color: #282828;
    }

    .basement-footer {
        width: 300px;
        display: flex;
        justify-content: space-between;
        align-items: center;
     
    }

    .title-copyright {
        font-size: 12px;
        color: #282828;
        margin: 0;
    }

    .title-country {
        font-size: 12px;
        color: #282828;
        margin: 0;
        
    }
}