html { font-size: 14px; }
@media (min-width: 768px) { html { font-size: 16px; } }

:root {
    --primary: #e87c1e;
    --primary-dark: #d06a10;
    --primary-light: #fff3e6;
    --dark: #595858;
    --dark-light: #5c5c5c;
    --text: #1a1a1a;
    --text-muted: #6b7280;
    --bg: #f8f5f0;
    --bg-alt: #ffffff;
    --border: #e5e7eb;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ===== ANIMATIONS ===== */
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-15px); } }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
@keyframes glow { 0%, 100% { box-shadow: 0 0 20px rgba(232,124,30,0.3); } 50% { box-shadow: 0 0 40px rgba(232,124,30,0.6); } }
@keyframes slideUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }
@keyframes gradientMove { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes scaleIn { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: scale(1); } }

.animate-float { animation: float 4s ease-in-out infinite; }
.animate-pulse { animation: pulse 3s ease-in-out infinite; }
.animate-glow { animation: glow 3s ease-in-out infinite; }
.animate-bounce { animation: bounce 2s ease-in-out infinite; }

.animate-slide-up { animation: slideUp 0.6s ease-out forwards; opacity: 0; }
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

/* ===== NAVBAR ===== */
.navbar {
    padding: 0.5rem 0;
    background: var(--dark) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.navbar-brand { height: 45px; }

/* ===== HERO ===== */
.hero-section {
    background: url('/images/logo_1.jpg') center/cover no-repeat;
    color: white;
    padding: 100px 0 60px;
    position: relative;
    overflow: hidden;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

@media (max-width: 768px) {
    .hero-section {
        background: url('/images/logo_for_mobile.png') center/cover no-repeat;
    }
}

.hero-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(30,30,30,0.55) 0%, rgba(25,25,25,0.50) 50%, rgba(35,35,35,0.45) 100%);
    z-index: 1;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -150px;
    left: -100px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255,255,255,0.03) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 10s ease-in-out infinite reverse;
}

.hero-section h1 {
    font-size: clamp(2.2rem, 5vw, 3.2rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -1px;
}

.hero-section .lead {
    font-size: 1.15rem;
    opacity: 0.85;
    max-width: 500px;
    line-height: 1.6;
}

.hero-image {
    animation: float 5s ease-in-out infinite;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.3));
}

.hero-image img {
    transition: transform 0.5s ease;
}

.hero-image:hover img {
    transform: scale(1.02);
}

.hero-badge { animation: pulse 3s ease-in-out infinite; }

/* ===== SECTIONS ===== */
section { padding: 5rem 0; }

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.section-title::after {
    content: '';
    display: block;
    width: 50px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), #f59e0b);
    border-radius: 2px;
    margin: 12px auto 0;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ===== CARDS ===== */
.feature-card {
    background: var(--bg-alt);
    border-radius: 20px;
    padding: 0;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid var(--border);
    height: 100%;
    overflow: hidden;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.feature-card-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.feature-card-body {
    padding: 1.5rem;
}

.feature-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary-light), #ffedd5);
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    color: var(--primary);
    margin-bottom: 1rem;
    transition: all 0.3s;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    color: white;
}

.service-card {
    background: var(--bg-alt);
    border-radius: 16px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s;
    border: 1px solid var(--border);
    height: 100%;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.06);
    border-color: var(--primary);
}

.service-card i {
    font-size: 32px;
    color: var(--primary);
    margin-bottom: 0.75rem;
    transition: transform 0.3s;
}

.service-card:hover i { transform: scale(1.15); }

.dir-icon {
    width: 48px;
    height: 48px;
    object-fit: contain;
    margin-bottom: 0.75rem;
    filter: invert(43%) sepia(89%) saturate(1462%) hue-rotate(346deg) brightness(97%) contrast(91%);
    transition: transform 0.3s;
}

.service-card:hover .dir-icon { transform: scale(1.15); }

.benefit-card {
    background: var(--bg-alt);
    border-radius: 16px;
    padding: 1.5rem;
    transition: all 0.3s;
    border: 1px solid var(--border);
    height: 100%;
}

.benefit-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.06);
}

/* ===== STAT ITEMS ===== */
.stat-item { text-align: center; padding: 1rem; }

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
    animation: pulse 3s ease-in-out infinite;
}

.stat-label {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
    margin-top: 0.5rem;
}

/* ===== REVIEWS ===== */
.implant-card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 12px 30px rgba(0,0,0,0.1) !important;
}

.review-card {
    background: var(--bg-alt);
    border-radius: 16px;
    padding: 1.5rem;
    transition: all 0.3s;
    border: 1px solid var(--border);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.review-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.06);
}

.review-text {
    position: relative;
    max-height: 6em;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.review-text.expanded {
    max-height: 600px;
}

.review-text.has-more:not(.expanded)::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2.5em;
    background: linear-gradient(transparent, var(--bg-alt));
    pointer-events: none;
}

.review-toggle {
    background: none !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    margin-top: 8px;
    transition: opacity 0.3s;
    display: inline-block;
    width: auto;
    text-align: left;
    line-height: 1.4;
    opacity: 0.8;
}

.review-toggle:hover {
    opacity: 1;
    background: none !important;
    box-shadow: none !important;
}

.review-text.expanded {
    max-height: 600px;
}
}

.review-toggle {
    background: none !important;
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 0;
    margin-top: 4px;
    transition: color 0.3s;
    display: inline-block;
    width: auto;
    text-align: left;
    line-height: 1.4;
}

.review-toggle:hover {
    color: var(--primary-dark);
    background: none !important;
    box-shadow: none !important;
}

.review-avatar {
    width: 45px;
    height: 45px;
    background: var(--dark);
    color: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
    flex-shrink: 0;
}

/* ===== INFO BLOCKS (Tourism) ===== */
.info-block {
    background: var(--bg);
    border-radius: 16px;
    padding: 1.25rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    height: 100%;
    transition: all 0.3s;
    border: 1px solid transparent;
}

.info-block:hover {
    border-color: var(--border);
    box-shadow: 0 8px 20px rgba(0,0,0,0.04);
}

.info-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

/* ===== TABLE ===== */
.comparison-table {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.comparison-table thead th {
    background: var(--dark);
    color: white;
    padding: 16px 20px;
    font-weight: 600;
    font-size: 0.9rem;
    border: none;
}

.comparison-table tbody td {
    padding: 14px 20px;
    border-color: var(--border);
    vertical-align: middle;
}

.comparison-table tbody tr:hover {
    background: var(--primary-light);
}

.comparison-table tbody tr:last-child {
    background: #e8f5e9;
}

/* ===== ACCORDION ===== */
.accordion-item {
    border: 1px solid var(--border) !important;
    border-radius: 12px !important;
    margin-bottom: 0.75rem;
    overflow: hidden;
}

.accordion-button {
    font-weight: 600;
    padding: 1rem 1.25rem;
    color: var(--text);
}

.accordion-button:not(.collapsed) {
    background: var(--primary-light);
    color: var(--primary);
    box-shadow: none;
}

.accordion-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23e87c1e'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

/* ===== CTA ===== */
.cta-section {
    background: linear-gradient(135deg, var(--dark) 0%, #3a3a3a 50%, var(--dark-light) 100%);
    background-size: 200% 200%;
    animation: gradientMove 10s ease infinite;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(232,124,30,0.15) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

/* ===== BUTTONS ===== */
.btn-primary {
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    border: none;
    font-weight: 600;
    transition: all 0.3s;
    border-radius: 12px;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(232,124,30,0.4);
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
    border-radius: 12px;
    font-weight: 600;
}

.btn-outline-primary:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.btn-outline-light:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255,255,255,0.2);
}

/* ===== FORM ===== */
.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(232,124,30,0.15);
}

/* ===== BADGE ===== */
.badge {
    background: var(--primary) !important;
    color: white !important;
}

/* ===== FOOTER ===== */
footer {
    background: var(--dark) !important;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: white;
}

footer h6 { color: white; font-weight: 600; }
footer p { color: rgba(255,255,255,0.7); }
footer a { color: rgba(255,255,255,0.8); transition: color 0.3s; }
footer a:hover { color: white; }

/* ===== CHAT WIDGET ===== */
.chat-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1050;
}

.chat-preview {
    position: absolute;
    bottom: 76px;
    right: 0;
    background: white;
    border-radius: 16px 16px 0 16px;
    padding: 14px 18px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
    max-width: 260px;
    opacity: 0;
    transform: translateY(10px) scale(0.95);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none;
    border: 1px solid rgba(0,0,0,0.05);
}
.chat-preview.show {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}
.chat-preview-text {
    font-size: 0.85rem;
    color: var(--gray-700, #374151);
    line-height: 1.5;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 30px rgba(232,124,30,0.4);
    transition: all 0.3s;
    animation: glow 3s ease-in-out infinite;
    position: relative;
}

.chat-toggle:hover {
    transform: scale(1.1) rotate(5deg);
}

.chat-toggle i { color: white; font-size: 24px; }

.chat-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #10b981;
    color: white;
    font-size: 0.6rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 8px;
    letter-spacing: 0.5px;
    border: 2px solid white;
    animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

.chat-box {
    position: absolute;
    bottom: 72px;
    right: 0;
    width: 360px;
    height: 480px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: scaleIn 0.3s ease-out;
}

.chat-header {
    background: linear-gradient(135deg, var(--dark), var(--dark-light));
    color: white;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: var(--bg);
}

.chat-message {
    max-width: 82%;
    padding: 12px 16px;
    border-radius: 16px;
    font-size: 14px;
    line-height: 1.5;
    word-wrap: break-word;
    animation: slideUp 0.3s ease-out;
}

.chat-message.user {
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.chat-message.bot {
    background: white;
    color: var(--text);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.chat-input {
    padding: 12px 16px;
    border-top: 1px solid var(--border);
    background: white;
}

.chat-input .form-control {
    border-radius: 24px;
    padding: 10px 16px;
    font-size: 14px;
    border: 1px solid var(--border);
}

.chat-input .btn {
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.chat-typing {
    display: flex;
    gap: 5px;
    padding: 12px 16px;
    align-self: flex-start;
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.chat-typing span {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    animation: bounce 1.4s infinite;
}

.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }

.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-thumb { background: #d1d5db; border-radius: 2px; }

/* ===== SCROLL REVEAL ===== */
.reveal {
    opacity: 0;
    transform: translateY(25px);
    transition: all 0.7s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ===== TOOTH FLOAT ===== */
.tooth-float {
    position: absolute;
    opacity: 0.04;
    font-size: 100px;
    animation: float 6s ease-in-out infinite;
    pointer-events: none;
    z-index: 2;
}

.tooth-float:nth-child(1) { top: 10%; left: 5%; animation-delay: 0s; }
.tooth-float:nth-child(2) { top: 60%; right: 5%; animation-delay: 2s; font-size: 80px; }
.tooth-float:nth-child(3) { bottom: 10%; left: 15%; animation-delay: 4s; font-size: 60px; }

/* ===== UTILITIES ===== */
.text-gradient {
    background: linear-gradient(135deg, var(--primary), #f59e0b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-warm { background: var(--bg); }
.bg-card { background: var(--bg-alt); }

/* ===== COOKIE CONSENT ===== */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 16px 0;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.1);
    z-index: 1060;
    border-top: 2px solid var(--primary);
    animation: slideUp 0.5s ease-out;
}
