/* ============================= */
/* Global Styles */
/* ============================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --white: #ffffff;
    --border-color: #dee2e6;
    --border-radius: 8px;
    --box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

/* ============================= */
/* Container */
/* ============================= */

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================= */
/* Navbar */
/* ============================= */

.navbar {
    background-color: var(--white);
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.navbar-brand a {
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-menu {
    display: flex;
}

.navbar-list {
    list-style: none;
    display: flex;
    gap: 30px;
}

.navbar-list a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.navbar-list a:hover {
    color: var(--primary-color);
}

/* ============================= */
/* Main Content */
/* ============================= */

.main-content {
    min-height: calc(100vh - 200px);
    padding: 40px 0;
}

/* ============================= */
/* Hero Section */
/* ============================= */

.hero {
    text-align: center;
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    color: var(--white);
    border-radius: var(--border-radius);
    margin-bottom: 60px;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.hero p {
    font-size: 20px;
    margin-bottom: 30px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* ============================= */
/* Features Section */
/* ============================= */

.features {
    margin-bottom: 60px;
}

.features h2 {
    text-align: center;
    font-size: 32px;
    margin-bottom: 40px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-card {
    background: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    text-align: center;
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.feature-card i {
    font-size: 40px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.feature-card h3 {
    margin-bottom: 15px;
    font-size: 20px;
}

/* ============================= */
/* Buttons */
/* ============================= */

.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
    text-align: center;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: #5a6268;
}

.btn-danger {
    background-color: var(--danger-color);
    color: var(--white);
}

.btn-danger:hover {
    background-color: #c82333;
}

.btn-block {
    width: 100%;
    display: block;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 12px;
}

/* ============================= */
/* Forms */
/* ============================= */

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.form-section {
    background: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    box-shadow: var(--box-shadow);
}

.form-section h2 {
    font-size: 20px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

/* ============================= */
/* Auth Container */
/* ============================= */

.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
}

.auth-box {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    width: 100%;
    max-width: 400px;
}

.auth-box h2 {
    text-align: center;
    margin-bottom: 30px;
    color: var(--primary-color);
}

.auth-link {
    text-align: center;
    margin-top: 20px;
}

.auth-link a {
    color: var(--primary-color);
    text-decoration: none;
}

.auth-link a:hover {
    text-decoration: underline;
}

/* ============================= */
/* Alerts */
/* ============================= */

.alert {
    padding: 15px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
}

.alert-error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-warning {
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
}

/* ============================= */
/* Dashboard */
/* ============================= */

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    background: var(--white);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.dashboard-header h1 {
    font-size: 28px;
}

.cards-section h2 {
    margin-bottom: 30px;
    font-size: 24px;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.card-item {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: transform 0.3s;
}

/* Card View Styles */
.card-view-container {
    margin: 40px 0;
}

.card-view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.card-view-actions {
    display: flex;
    gap: 10px;
}

.card-view-grid {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 30px;
}

.card-preview-section, .card-info-section {
    background: var(--white);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.card-view {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    border-radius: 12px;
    min-height: 180px;
}

.card-info h1 {
    font-size: 22px;
    margin-bottom: 6px;
}

.card-info .job-title, .card-info .company {
    opacity: 0.9;
}

.card-qr img {
    width: 120px;
    height: 120px;
    object-fit: contain;
    background: var(--white);
    padding: 8px;
    border-radius: 8px;
}

.info-item input[type="text"] {
    width: calc(100% - 110px);
    display: inline-block;
    margin-right: 8px;
}

.btn-primary { background-color: var(--primary-color); color: var(--white); }
.btn-primary:hover { background-color: #0056b3; }

@media (max-width: 900px) {
    .card-view-grid { grid-template-columns: 1fr; }
    .card-qr img { width: 100px; height: 100px; }
}

/* Sharing inline controls */
.sharing-inline {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sharing-inline input[type="text"] {
    width: 100%;
    max-width: 520px;
}

.share-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

.btn-share {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--dark-color);
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

.btn-share i { font-size: 14px; }

.btn-share:hover {
    transform: translateY(-2px);
    border-color: rgba(0,0,0,0.08);
}

.card-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.card-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
}

.card-item-header h3 {
    margin: 0;
    font-size: 18px;
}

.card-actions {
    display: flex;
    gap: 10px;
}

.btn-action {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--secondary-color);
    font-size: 16px;
    transition: color 0.3s;
}

.btn-action:hover {
    color: var(--danger-color);
}

.card-item-body {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
}

.card-item-body p {
    margin: 5px 0;
    font-size: 14px;
}

.card-item-footer {
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-stats {
    font-size: 14px;
    color: var(--secondary-color);
}

.card-buttons {
    display: flex;
    gap: 10px;
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.empty-state i {
    font-size: 64px;
    color: var(--border-color);
    margin-bottom: 20px;
}

.empty-state h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

.empty-state p {
    color: var(--secondary-color);
    margin-bottom: 20px;
}

/* ============================= */
/* Card View */
/* ============================= */

.card-view {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 40px;
    margin-bottom: 30px;
    box-shadow: var(--box-shadow);
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 40px;
    align-items: center;
    min-height: 400px;
}

.card-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    overflow: hidden;
}

.card-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-avatar i {
    font-size: 48px;
    color: rgba(255, 255, 255, 0.5);
}

.card-info h1 {
    font-size: 36px;
    margin-bottom: 10px;
}

.job-title {
    font-size: 20px;
    font-weight: 500;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.company {
    font-size: 16px;
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.bio {
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 1.6;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 14px;
}

.detail-item i {
    width: 20px;
    text-align: center;
    color: var(--primary-color);
}

.detail-item a {
    color: var(--primary-color);
    text-decoration: none;
}

.detail-item a:hover {
    text-decoration: underline;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    display: inline-flex;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    transition: background-color 0.3s;
}

.social-links a:hover {
    background: #0056b3;
}

.card-qr {
    text-align: center;
}

.card-qr img {
    width: 200px;
    height: 200px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    padding: 10px;
    background: var(--white);
}

.card-qr p {
    font-size: 12px;
    margin-top: 10px;
    color: var(--secondary-color);
}

/* ============================= */
/* Contact Form */
/* ============================= */

.contact-form-section {
    background: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.contact-form-section h2 {
    margin-bottom: 20px;
    font-size: 24px;
}

.contact-form {
    max-width: 500px;
}

.form-message {
    margin-top: 20px;
    padding: 15px 20px;
    border-radius: var(--border-radius);
    display: none;
}

.form-message.success {
    display: block;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.form-message.error {
    display: block;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* ============================= */
/* Card View Container */
/* ============================= */

.card-view-container {
    background: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.card-view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.card-view-header h1 {
    font-size: 28px;
}

.card-view-actions {
    display: flex;
    gap: 10px;
}

.card-view-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
}

.card-preview-section h2 {
    margin-bottom: 20px;
    font-size: 20px;
}

.card-info-section h2 {
    margin-bottom: 20px;
    font-size: 20px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
}

.info-group {
    margin-bottom: 30px;
}

.info-group h3 {
    font-size: 16px;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.info-item {
    margin-bottom: 15px;
}

.info-item label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 14px;
}

.info-item input {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    margin-bottom: 10px;
}

.analytics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.stat {
    background: var(--light-color);
    padding: 20px;
    border-radius: var(--border-radius);
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 28px;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.stat-label {
    display: block;
    font-size: 12px;
    color: var(--secondary-color);
}

.info-table {
    width: 100%;
    border-collapse: collapse;
}

.info-table th {
    text-align: left;
    padding: 12px;
    background: var(--light-color);
    font-weight: 500;
    border-bottom: 1px solid var(--border-color);
}

.info-table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
}

/* ============================= */
/* Modal */
/* ============================= */

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: var(--white);
    margin: 50px auto;
    padding: 30px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    max-width: 500px;
    animation: slideIn 0.3s;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-close {
    color: var(--secondary-color);
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.modal-close:hover {
    color: var(--danger-color);
}

.modal-buttons {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    justify-content: flex-end;
}

/* ============================= */
/* Footer */
/* ============================= */

.footer {
    background-color: var(--dark-color);
    color: var(--white);
    text-align: center;
    padding: 30px 0;
    margin-top: 60px;
}

.footer p {
    margin: 5px 0;
}

/* ============================= */
/* Responsive */
/* ============================= */

@media (max-width: 768px) {
    .hero {
        padding: 40px 0;
    }
    
    .hero h1 {
        font-size: 32px;
    }
    
    .hero p {
        font-size: 16px;
    }
    
    .navbar .container {
        flex-direction: column;
        gap: 15px;
    }
    
    .navbar-list {
        gap: 15px;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .card-view {
        grid-template-columns: 1fr;
    }
    
    .card-view-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .analytics-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero h1 {
        font-size: 24px;
    }
    
    .card-view {
        padding: 20px;
    }
}
