/* ========================================
   SecurePay™ - Phishing Demo Styles
   For Security Awareness Training
   ======================================== */

:root {
    /* Color Palette - Dark Luxury Theme */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: rgba(18, 18, 26, 0.85);
    --bg-input: rgba(255, 255, 255, 0.03);
    
    /* Accent Colors */
    --accent-primary: #00F5A0;
    --accent-secondary: #00D9F5;
    --accent-gradient: linear-gradient(135deg, #00F5A0 0%, #00D9F5 100%);
    --accent-glow: rgba(0, 245, 160, 0.3);
    
    /* Text Colors */
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.4);
    
    /* Borders & Shadows */
    --border-color: rgba(255, 255, 255, 0.08);
    --border-focus: rgba(0, 245, 160, 0.5);
    --shadow-card: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 60px rgba(0, 245, 160, 0.15);
    
    /* Spacing */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 24px;
    
    /* Typography */
    --font-primary: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   Background Effects
   ======================================== */

.bg-gradient {
    position: fixed;
    inset: 0;
    background: 
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(0, 245, 160, 0.15), transparent),
        radial-gradient(ellipse 60% 40% at 100% 100%, rgba(0, 217, 245, 0.1), transparent),
        radial-gradient(ellipse 50% 30% at 0% 80%, rgba(120, 0, 255, 0.08), transparent);
    pointer-events: none;
    z-index: -2;
}

.grid-overlay {
    position: fixed;
    inset: 0;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: -1;
}

.floating-orbs {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: -1;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: float 20s infinite ease-in-out;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: var(--accent-primary);
    top: -200px;
    right: -100px;
    animation-delay: 0s;
}

.orb-2 {
    width: 300px;
    height: 300px;
    background: var(--accent-secondary);
    bottom: -150px;
    left: -100px;
    animation-delay: -7s;
}

.orb-3 {
    width: 200px;
    height: 200px;
    background: #7B00FF;
    top: 50%;
    left: 50%;
    animation-delay: -14s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -30px) scale(1.05); }
    50% { transform: translate(-20px, 20px) scale(0.95); }
    75% { transform: translate(-30px, -20px) scale(1.02); }
}

/* ========================================
   Security Badge
   ======================================== */

.security-badge {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(0, 245, 160, 0.1);
    border: 1px solid rgba(0, 245, 160, 0.3);
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-primary);
    backdrop-filter: blur(10px);
    z-index: 100;
    animation: pulse 3s infinite ease-in-out;
}

.security-badge svg {
    width: 16px;
    height: 16px;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0, 245, 160, 0.4); }
    50% { box-shadow: 0 0 0 10px rgba(0, 245, 160, 0); }
}

/* ========================================
   Main Container
   ======================================== */

.container {
    max-width: 560px;
    margin: 0 auto;
    padding: 40px 20px 60px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   Header
   ======================================== */

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 0 4px;
}

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

.logo-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon svg {
    width: 100%;
    height: 100%;
}

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

.logo-name {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo-badge {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--accent-primary);
    opacity: 0.8;
}

.trust-indicators {
    display: flex;
    align-items: center;
    gap: 16px;
}

.indicator {
    text-align: right;
}

.indicator-value {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
}

.indicator-label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.indicator-divider {
    width: 1px;
    height: 30px;
    background: var(--border-color);
}

/* ========================================
   Payment Card
   ======================================== */

.payment-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 40px;
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-card);
    animation: cardAppear 0.6s ease-out 0.2s both;
}

@keyframes cardAppear {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.card-glow {
    position: absolute;
    top: -1px;
    left: 20%;
    right: 20%;
    height: 2px;
    background: var(--accent-gradient);
    border-radius: 100px;
    filter: blur(1px);
}

.card-header {
    text-align: center;
    margin-bottom: 36px;
}

.card-header h1 {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 8px;
}

.card-header p {
    color: var(--text-secondary);
    font-size: 15px;
}

/* ========================================
   Form Sections
   ======================================== */

.form-section {
    margin-bottom: 32px;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.section-number {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 500;
    color: var(--accent-primary);
    padding: 4px 10px;
    background: rgba(0, 245, 160, 0.1);
    border-radius: 100px;
}

.section-title {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
}

/* ========================================
   Input Groups
   ======================================== */

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 16px;
    width: 18px;
    height: 18px;
    color: var(--text-muted);
    pointer-events: none;
    transition: color var(--transition-fast);
}

.input-wrapper input {
    width: 100%;
    padding: 16px 16px 16px 48px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 15px;
    transition: all var(--transition-fast);
}

.input-wrapper.has-prefix input {
    padding-left: 40px;
}

.input-prefix {
    position: absolute;
    left: 16px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-muted);
}

.input-wrapper input::placeholder {
    color: var(--text-muted);
}

.input-wrapper input:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--border-focus);
    background: rgba(0, 245, 160, 0.03);
    box-shadow: 0 0 0 4px rgba(0, 245, 160, 0.1);
}

.input-wrapper input:focus + .input-icon,
.input-wrapper:focus-within .input-icon {
    color: var(--accent-primary);
}

.input-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.card-icons {
    position: absolute;
    right: 16px;
    display: flex;
    gap: 8px;
    opacity: 0.6;
}

.card-icon {
    height: 20px;
    width: auto;
}

/* CVV Hint */
.cvv-hint {
    position: relative;
    cursor: help;
}

.cvv-hint svg {
    width: 14px;
    height: 14px;
    color: var(--text-muted);
}

.cvv-hint::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    padding: 8px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 400;
    color: var(--text-secondary);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-fast);
    z-index: 10;
}

.cvv-hint:hover::after {
    opacity: 1;
    visibility: visible;
}

/* ========================================
   Credit Card Preview
   ======================================== */

.credit-card-preview {
    position: relative;
    width: 100%;
    aspect-ratio: 1.6;
    max-width: 380px;
    margin: 0 auto 28px;
    padding: 28px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    border-radius: var(--radius-lg);
    box-shadow: 
        0 25px 40px -10px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    overflow: hidden;
    transform-style: preserve-3d;
    transition: transform var(--transition-slow);
}

.credit-card-preview::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.1), transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(0, 245, 160, 0.1), transparent 40%);
    pointer-events: none;
}

.credit-card-preview:hover {
    transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
}

.card-chip {
    width: 50px;
    height: 38px;
    margin-bottom: 24px;
}

.card-number-display {
    display: flex;
    gap: 16px;
    font-family: var(--font-mono);
    font-size: 22px;
    font-weight: 500;
    letter-spacing: 2px;
    margin-bottom: 24px;
}

.card-number-display span {
    transition: all var(--transition-fast);
}

.card-details-display {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.cardholder-display,
.expiry-display {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cardholder-display .label,
.expiry-display .label {
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.5);
}

.cardholder-display .value,
.expiry-display .value {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.card-brand {
    position: absolute;
    top: 28px;
    right: 28px;
}

.visa-logo {
    width: 60px;
    height: auto;
}

/* ========================================
   Summary
   ======================================== */

.summary {
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-md);
    padding: 20px 24px;
    margin-bottom: 24px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
    color: var(--text-secondary);
}

.summary-row.total {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

.summary-row .fee {
    color: var(--accent-primary);
}

.summary-divider {
    height: 1px;
    background: var(--border-color);
    margin: 8px 0;
}

/* ========================================
   Submit Button
   ======================================== */

.submit-btn {
    position: relative;
    width: 100%;
    padding: 18px 32px;
    background: var(--accent-gradient);
    border: none;
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-size: 16px;
    font-weight: 600;
    color: #0a0a0f;
    cursor: pointer;
    overflow: hidden;
    transition: all var(--transition-base);
}

.submit-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.submit-btn:hover::before {
    opacity: 1;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px -10px rgba(0, 245, 160, 0.5);
}

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

.btn-text,
.btn-icon,
.btn-loader {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all var(--transition-fast);
}

.btn-icon svg {
    width: 18px;
    height: 18px;
}

.btn-loader {
    position: absolute;
    opacity: 0;
}

.btn-loader svg {
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.submit-btn.loading .btn-text,
.submit-btn.loading .btn-icon {
    opacity: 0;
}

.submit-btn.loading .btn-loader {
    opacity: 1;
}

/* ========================================
   Security Note
   ======================================== */

.security-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    font-size: 13px;
    color: var(--text-muted);
}

.security-note svg {
    width: 16px;
    height: 16px;
    color: var(--accent-primary);
}

/* ========================================
   Trust Badges
   ======================================== */

.trust-badges {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-muted);
}

.badge svg {
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
}

/* ========================================
   Footer
   ======================================== */

.footer {
    margin-top: auto;
    padding-top: 40px;
    text-align: center;
}

.footer p {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
}

.footer-links a {
    font-size: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: var(--accent-primary);
}

/* ========================================
   Modal
   ======================================== */

.modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
    z-index: 1000;
    padding: 20px;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 48px 40px;
    max-width: 400px;
    width: 100%;
    text-align: center;
    transform: scale(0.9);
    transition: transform var(--transition-slow);
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(0, 245, 160, 0.1);
}

.modal-icon svg {
    width: 40px;
    height: 40px;
    color: var(--accent-primary);
}

.modal-content h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

.modal-content p {
    color: var(--text-secondary);
    margin-bottom: 28px;
}

.modal-details {
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 28px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
}

.detail-row span:first-child {
    color: var(--text-muted);
}

.detail-row span:last-child {
    font-family: var(--font-mono);
    font-weight: 500;
}

.modal-btn {
    width: 100%;
    padding: 16px;
    background: var(--accent-gradient);
    border: none;
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-size: 15px;
    font-weight: 600;
    color: #0a0a0f;
    cursor: pointer;
    transition: all var(--transition-base);
}

.modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px -10px rgba(0, 245, 160, 0.5);
}

/* ========================================
   Responsive Design
   ======================================== */

@media (max-width: 600px) {
    .container {
        padding: 24px 16px 100px;
    }

    .header {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .logo {
        justify-content: center;
    }

    .payment-card {
        padding: 28px 20px;
    }

    .card-header h1 {
        font-size: 24px;
    }

    .input-row {
        grid-template-columns: 1fr;
    }

    .credit-card-preview {
        padding: 20px;
    }

    .card-number-display {
        font-size: 16px;
        gap: 8px;
    }

    .trust-badges {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }

    .security-badge {
        top: 10px;
        right: 10px;
        padding: 8px 12px;
        font-size: 10px;
    }

}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

