/* Reset та базові стилі */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Темні кольори бренду */
    --dark-1: #131415;
    --dark-2: #252526;
    --dark-3: #0E0C07;
    
    /* Золоті кольори бренду */
    --gold-1: #D6BC69;
    --gold-2: #D6BB68;
    --gold-3: #D5BD60;
    --gold-4: #D7BD66;
    --gold-5: #D8B966;
    
    /* Основний золотий колір */
    --gold: #D6BC69;
    
    /* Фон та текст */
    --bg-primary: #131415;
    --bg-secondary: #252526;
    --bg-tertiary: #0E0C07;
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    
    /* Шрифти */
    --font-bold: 'Inter', sans-serif;
    --font-regular: 'Inter', sans-serif;
}

body {
    font-family: var(--font-regular);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    font-weight: 400;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
    padding: 20px 0;
    border-bottom: 2px solid var(--gold);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 20px rgba(214, 188, 105, 0.1);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(214, 188, 105, 0.5));
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-title {
    font-family: var(--font-bold);
    font-size: 32px;
    font-weight: 700;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(214, 188, 105, 0.3);
    margin: 0;
    line-height: 1;
}

.logo-subtitle {
    font-family: var(--font-regular);
    font-size: 14px;
    color: var(--gold-4);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin: 0;
    font-weight: 400;
}

.nav {
    display: flex;
    gap: 30px;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 5px 0;
}

.nav-link:hover {
    color: var(--gold);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    padding: 80px 0;
    text-align: center;
    border-bottom: 1px solid rgba(214, 188, 105, 0.2);
}

.hero-title {
    font-family: var(--font-bold);
    font-size: 48px;
    font-weight: 700;
    color: var(--gold);
    margin-bottom: 15px;
    text-shadow: 0 2px 20px rgba(214, 188, 105, 0.3);
}

.hero-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    font-weight: 400;
}

/* Rates Section */
.rates-section {
    padding: 60px 0;
}

.section-title {
    font-family: var(--font-bold);
    font-size: 36px;
    font-weight: 700;
    color: var(--gold);
    margin-bottom: 30px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.amount-selector {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
}

.amount-btn {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid rgba(214, 188, 105, 0.3);
    border-radius: 8px;
    padding: 12px 24px;
    color: var(--text-secondary);
    font-family: var(--font-regular);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.amount-btn:hover {
    border-color: var(--gold);
    color: var(--gold);
    transform: translateY(-2px);
}

.amount-btn.active {
    background: linear-gradient(135deg, var(--gold-1) 0%, var(--gold-5) 100%);
    border-color: var(--gold);
    color: var(--bg-primary);
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(214, 188, 105, 0.3);
}

.rates-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 25px;
}

.rate-card {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid rgba(214, 188, 105, 0.3);
    border-radius: 12px;
    padding: 25px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    flex: 0 0 300px;
    max-width: 100%;
}

.rate-card:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: 0 8px 25px rgba(214, 188, 105, 0.2);
}

.rate-card.loading {
    opacity: 0.6;
}

.rate-card-header {
    margin-bottom: 20px;
}

.currency-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.currency-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--gold-1) 0%, var(--gold-5) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    color: var(--bg-primary);
    box-shadow: 0 4px 15px rgba(214, 188, 105, 0.3);
}

.currency-name {
    font-family: var(--font-bold);
    font-size: 24px;
    font-weight: 700;
    color: var(--gold);
    margin: 0;
}

.currency-full {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
}

.rate-card-body {
    padding-top: 15px;
    border-top: 1px solid rgba(214, 188, 105, 0.2);
}

.rate-value {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.rate-buy,
.rate-sell {
    display: flex;
    justify-content: space-between;
    font-size: 16px;
    color: var(--text-secondary);
}

.rate-buy .value,
.rate-sell .value {
    font-family: var(--font-bold);
    font-size: 20px;
    font-weight: 700;
    color: var(--gold);
}

.rate-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(214, 188, 105, 0.2);
}

.action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-family: var(--font-regular);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.action-btn:hover::before {
    width: 300px;
    height: 300px;
}

.action-btn svg {
    transition: transform 0.3s ease;
}

.action-btn:hover svg {
    transform: scale(1.1);
}

.action-btn:active {
    transform: scale(0.98);
}

.action-btn-buy {
    background: linear-gradient(135deg, #2d5016 0%, #4a7c2a 100%);
    color: #ffffff;
    border: 1px solid rgba(76, 124, 42, 0.5);
    box-shadow: 0 4px 15px rgba(76, 124, 42, 0.3);
}

.action-btn-buy:hover {
    background: linear-gradient(135deg, #4a7c2a 0%, #5d9a35 100%);
    border-color: rgba(93, 154, 53, 0.8);
    box-shadow: 0 6px 20px rgba(76, 124, 42, 0.4);
    transform: translateY(-2px);
}

.action-btn-sell {
    background: linear-gradient(135deg, #7c2a2a 0%, #9a3535 100%);
    color: #ffffff;
    border: 1px solid rgba(154, 53, 53, 0.5);
    box-shadow: 0 4px 15px rgba(154, 53, 53, 0.3);
}

.action-btn-sell:hover {
    background: linear-gradient(135deg, #9a3535 0%, #b84242 100%);
    border-color: rgba(184, 66, 66, 0.8);
    box-shadow: 0 6px 20px rgba(154, 53, 53, 0.4);
    transform: translateY(-2px);
}

.action-btn span {
    position: relative;
    z-index: 1;
}

.action-btn svg {
    position: relative;
    z-index: 1;
}

/* Анімація пульсації для калькулятора */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
}

/* Calculator Section */
.calculator-section {
    padding: 60px 0;
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
    border-top: 1px solid rgba(214, 188, 105, 0.2);
}

.calculator {
    max-width: 900px;
    margin: 0 auto;
}

.calculator-card {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid rgba(214, 188, 105, 0.3);
    border-radius: 20px;
    padding: 50px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    position: relative;
}

.calculator-from,
.calculator-to {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.currency-label {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.currency-select-wrapper {
    position: relative;
}

.currency-select {
    width: 100%;
    background: var(--bg-primary);
    border: 2px solid rgba(214, 188, 105, 0.3);
    border-radius: 12px;
    padding: 16px 20px;
    color: var(--text-primary);
    font-size: 18px;
    font-family: var(--font-regular);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%23D6BC69' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 20px center;
    padding-right: 50px;
}

.currency-select:hover {
    border-color: var(--gold);
}

.currency-select:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(214, 188, 105, 0.3);
}

.amount-input-wrapper {
    position: relative;
}

.amount-input {
    width: 100%;
    background: var(--bg-primary);
    border: 2px solid rgba(214, 188, 105, 0.3);
    border-radius: 12px;
    padding: 20px 25px;
    color: var(--text-primary);
    font-size: 32px;
    font-family: var(--font-bold);
    font-weight: 700;
    transition: all 0.3s ease;
    text-align: left;
}

.amount-input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 20px rgba(214, 188, 105, 0.3);
    transform: translateY(-2px);
}

.amount-input::placeholder {
    color: var(--text-secondary);
    opacity: 0.5;
}

.swap-button {
    align-self: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold-1) 0%, var(--gold-5) 100%);
    border: none;
    color: var(--bg-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(214, 188, 105, 0.4);
    position: relative;
    z-index: 10;
}

.swap-button:hover {
    transform: rotate(180deg) scale(1.1);
    box-shadow: 0 6px 20px rgba(214, 188, 105, 0.5);
}

.swap-button:active {
    transform: rotate(180deg) scale(0.95);
}

.result-wrapper {
    position: relative;
}

.result-value {
    background: linear-gradient(135deg, var(--gold-1) 0%, var(--gold-5) 100%);
    color: var(--bg-primary);
    padding: 25px 30px;
    border-radius: 12px;
    font-family: var(--font-bold);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 15px rgba(214, 188, 105, 0.3);
    min-height: 80px;
    transition: all 0.3s ease;
}

.result-value:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(214, 188, 105, 0.4);
}

.result-amount {
    font-size: 36px;
    line-height: 1;
}

.result-currency {
    font-size: 20px;
    opacity: 0.9;
    font-weight: 600;
}

.currency-rate-info {
    margin-top: 8px;
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 400;
    opacity: 0.7;
}

.calculator-info {
    text-align: center;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.info-text {
    color: var(--text-secondary);
    font-size: 14px;
    font-style: italic;
}

.order-button {
    background: linear-gradient(135deg, var(--gold-1) 0%, var(--gold-5) 100%);
    border: none;
    border-radius: 12px;
    padding: 16px 40px;
    color: var(--bg-primary);
    font-family: var(--font-bold);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(214, 188, 105, 0.3);
}

.order-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(214, 188, 105, 0.4);
}

.order-button:active {
    transform: translateY(0);
}

/* Order Section */
.order-section {
    padding: 60px 0;
    background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-secondary) 100%);
    border-top: 1px solid rgba(214, 188, 105, 0.2);
}

.order-form-wrapper {
    max-width: 900px;
    margin: 0 auto;
}

.order-form {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.order-summary {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid rgba(214, 188, 105, 0.3);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.summary-title {
    font-family: var(--font-bold);
    font-size: 24px;
    font-weight: 700;
    color: var(--gold);
    margin: 0 0 30px 0;
    text-align: center;
}

.summary-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: var(--bg-primary);
    border-radius: 12px;
    border: 1px solid rgba(214, 188, 105, 0.2);
}

.summary-label {
    font-size: 16px;
    color: var(--text-secondary);
    font-weight: 500;
}

.summary-value {
    font-family: var(--font-bold);
    font-size: 20px;
    font-weight: 700;
    color: var(--gold);
}

.order-contact-info {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border: 1px solid rgba(214, 188, 105, 0.3);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.contact-title {
    font-family: var(--font-bold);
    font-size: 24px;
    font-weight: 700;
    color: var(--gold);
    margin: 0 0 30px 0;
    text-align: center;
}

.contact-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.contact-field {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-field.full-width {
    grid-column: 1 / -1;
}

.contact-label {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.contact-input,
.contact-textarea {
    background: var(--bg-primary);
    border: 2px solid rgba(214, 188, 105, 0.3);
    border-radius: 12px;
    padding: 16px 20px;
    color: var(--text-primary);
    font-size: 16px;
    font-family: var(--font-regular);
    transition: all 0.3s ease;
}

.contact-input:focus,
.contact-textarea:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(214, 188, 105, 0.3);
}

.contact-textarea {
    resize: vertical;
    min-height: 100px;
    font-family: var(--font-regular);
}

.order-actions {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}

.submit-button {
    flex: 1;
    background: linear-gradient(135deg, var(--gold-1) 0%, var(--gold-5) 100%);
    border: none;
    border-radius: 12px;
    padding: 20px;
    color: var(--bg-primary);
    font-family: var(--font-bold);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(214, 188, 105, 0.3);
}

.cancel-button {
    flex: 0 0 auto;
    min-width: 150px;
    background: transparent;
    border: 2px solid rgba(214, 188, 105, 0.3);
    border-radius: 12px;
    padding: 20px 30px;
    color: var(--text-primary);
    font-family: var(--font-bold);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.cancel-button:hover {
    border-color: var(--gold);
    background: rgba(214, 188, 105, 0.1);
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(214, 188, 105, 0.4);
}

.submit-button:active {
    transform: translateY(0);
}

.submit-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.order-message {
    margin-top: 20px;
    padding: 15px 20px;
    border-radius: 12px;
    font-size: 16px;
    text-align: center;
    font-weight: 500;
}

.order-message.success {
    background: rgba(76, 175, 80, 0.2);
    border: 1px solid rgba(76, 175, 80, 0.5);
    color: #4CAF50;
}

.order-message.error {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.5);
    color: #f44336;
}

@media (max-width: 768px) {
    .order-calculator .calculator-card {
        padding: 30px 20px;
    }
    
    .order-contact-info {
        padding: 30px 20px;
    }
    
    .contact-fields {
        grid-template-columns: 1fr;
    }
}

/* Footer */
.footer {
    background: var(--bg-tertiary);
    padding: 30px 0;
    text-align: center;
    border-top: 1px solid rgba(214, 188, 105, 0.2);
}

.footer p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 20px;
    }

    .nav {
        gap: 20px;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .rates-grid {
        justify-content: center;
    }
    
    .rate-card {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    .rate-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .action-btn {
        width: 100%;
        padding: 14px 20px;
        font-size: 13px;
    }

    .calculator-card {
        padding: 30px 20px;
    }

    .amount-input {
        font-size: 24px;
        padding: 16px 20px;
    }

    .result-amount {
        font-size: 28px;
    }

    .result-currency {
        font-size: 16px;
    }

    .swap-button {
        width: 48px;
        height: 48px;
    }

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

/* Анімація завантаження */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.rate-card.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

