/* Dokunmatik testi özel stilleri */

.touch-container {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    border-radius: 15px;
    padding: 2rem;
    color: white;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Touch Test Area */
.touch-test-area {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    height: 500px;
    position: relative;
    overflow: hidden;
    touch-action: none;
    border: 2px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.test-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
    background: rgba(0, 0, 0, 0.85);
    padding: 2rem;
    border-radius: 10px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.test-overlay h3 {
    margin-bottom: 1rem;
    color: white;
}

.test-overlay p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 1.5rem;
}

.touch-icon {
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.6);
    animation: touch-pulse 2s infinite;
}

@keyframes touch-pulse {
    0%, 100% { transform: scale(1); opacity: 0.6; }
    50% { transform: scale(1.1); opacity: 1; }
}

/* Touch Canvas */
#touch-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    cursor: crosshair;
}

/* Touch Indicators */
.touch-indicators {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

.touch-indicator {
    position: absolute;
    width: 60px;
    height: 60px;
    border: 3px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    animation: touch-ripple 0.6s ease-out;
    pointer-events: none;
}

@keyframes touch-ripple {
    0% {
        width: 20px;
        height: 20px;
        opacity: 1;
    }
    100% {
        width: 80px;
        height: 80px;
        opacity: 0;
    }
}

.touch-point {
    position: absolute;
    width: 40px;
    height: 40px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0.3));
    border: 2px solid rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: touch-point-pulse 1s infinite;
    pointer-events: none;
}

@keyframes touch-point-pulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.1); }
}

/* Gesture Areas */
.gesture-areas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    padding: 1rem;
    z-index: 3;
}

.gesture-area {
    background: rgba(255, 255, 255, 0.1);
    border: 2px dashed rgba(255, 255, 255, 0.5);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    cursor: pointer;
}

.gesture-area:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.8);
    color: white;
}

.gesture-area.active {
    background: rgba(39, 174, 96, 0.3);
    border-color: #27ae60;
    color: white;
    animation: gesture-active 0.5s ease;
}

@keyframes gesture-active {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.gesture-area i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.gesture-area span {
    font-size: 0.9rem;
    font-weight: 500;
}

/* Click Targets */
.click-targets {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 4;
}

.click-target {
    position: absolute;
    width: 60px;
    height: 60px;
    background: rgba(52, 152, 219, 0.8);
    border: 3px solid #3498db;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    animation: click-target-pulse 2s infinite;
}

.click-target:hover {
    background: rgba(52, 152, 219, 1);
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(52, 152, 219, 0.6);
}

.click-target.clicked {
    background: rgba(39, 174, 96, 0.8);
    border-color: #27ae60;
    animation: click-success 0.5s ease;
}

@keyframes click-target-pulse {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.05); opacity: 1; }
}

@keyframes click-success {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* Drag and Drop */
.drag-test-area {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 4;
}

.drag-source {
    position: absolute;
    top: 50px;
    left: 50px;
    width: 120px;
    height: 60px;
    background: rgba(241, 196, 15, 0.9);
    border: 2px solid #f1c40f;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2c3e50;
    font-weight: bold;
    cursor: grab;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.drag-source:hover {
    background: rgba(241, 196, 15, 1);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
}

.drag-source.dragging {
    cursor: grabbing;
    transform: rotate(5deg) scale(1.05);
    opacity: 0.8;
    z-index: 10;
}

.drag-target {
    position: absolute;
    bottom: 50px;
    right: 50px;
    width: 140px;
    height: 80px;
    background: rgba(231, 76, 60, 0.3);
    border: 3px dashed #e74c3c;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.8);
    font-weight: bold;
    transition: all 0.3s ease;
}

.drag-target.drag-over {
    background: rgba(39, 174, 96, 0.4);
    border-color: #27ae60;
    border-style: solid;
    color: white;
    transform: scale(1.05);
}

.drag-target.drop-success {
    background: rgba(39, 174, 96, 0.6);
    border-color: #27ae60;
    animation: drop-success 1s ease;
}

@keyframes drop-success {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.1); }
    50% { transform: scale(1.15); }
    75% { transform: scale(1.05); }
}

.drag-target i {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
}

.drag-target span {
    font-size: 0.9rem;
    text-align: center;
}

/* Touch Controls */
.touch-controls {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.touch-controls .btn {
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.touch-controls .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Touch Stats */
.touch-stats {
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    padding: 1.5rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.stat-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.stat-card i {
    color: rgba(255, 255, 255, 0.8);
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

/* Touch Points Display */
.touch-points h6,
.gesture-recognition h6 {
    color: white;
    margin-bottom: 1rem;
    font-weight: 600;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 0.5rem;
}

.touch-points-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.5rem;
}

.touch-point-info {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 6px;
    padding: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.point-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
}

.point-coords {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 0.25rem;
}

.point-pressure {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 0.25rem;
}

/* Gesture Recognition */
.gesture-list {
    max-height: 150px;
    overflow-y: auto;
}

.gesture-item {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 6px;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.gesture-name {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.gesture-time {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
}

.gesture-success {
    border-color: #27ae60;
    background: rgba(39, 174, 96, 0.2);
}

.gesture-failed {
    border-color: #e74c3c;
    background: rgba(231, 76, 60, 0.2);
}

/* Touch Info */
.touch-info {
    border: 1px solid rgba(13, 110, 253, 0.1);
    transition: all 0.3s ease;
}

.touch-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.touch-info .badge {
    font-size: 0.8rem;
    margin-right: 0.5rem;
}

/* Pressure Visualization */
.pressure-indicator {
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.3));
    transform: translate(-50%, -50%);
    pointer-events: none;
    transition: all 0.1s ease;
}

.pressure-light { background: radial-gradient(circle, rgba(52, 152, 219, 0.8), rgba(52, 152, 219, 0.3)); }
.pressure-medium { background: radial-gradient(circle, rgba(241, 196, 15, 0.8), rgba(241, 196, 15, 0.3)); }
.pressure-heavy { background: radial-gradient(circle, rgba(231, 76, 60, 0.8), rgba(231, 76, 60, 0.3)); }

/* Drawing Trail */
.drawing-trail {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    pointer-events: none;
    animation: trail-fade 2s ease-out forwards;
}

@keyframes trail-fade {
    0% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(0.5); }
}

/* Responsive Design */
@media (max-width: 992px) {
    .touch-container {
        padding: 1rem;
    }
    
    .touch-test-area {
        height: 400px;
    }
    
    .gesture-areas {
        grid-template-columns: 1fr;
        gap: 0.5rem;
        padding: 0.5rem;
    }
    
    .gesture-area {
        min-height: 80px;
    }
    
    .gesture-area i {
        font-size: 1.5rem;
    }
    
    .gesture-area span {
        font-size: 0.8rem;
    }
    
    .touch-controls {
        padding: 1rem;
    }
    
    .touch-stats {
        padding: 1rem;
    }
    
    .stat-card {
        padding: 1rem;
        margin-bottom: 1rem;
    }
    
    .stat-value {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    .touch-test-area {
        height: 350px;
    }
    
    .test-overlay {
        padding: 1.5rem;
    }
    
    .test-overlay h3 {
        font-size: 1.2rem;
    }
    
    .touch-icon {
        font-size: 2rem;
    }
    
    .touch-indicator {
        width: 50px;
        height: 50px;
    }
    
    .touch-point {
        width: 30px;
        height: 30px;
    }
    
    .gesture-area {
        min-height: 60px;
        padding: 0.5rem;
    }
    
    .gesture-area i {
        font-size: 1.2rem;
    }
    
    .gesture-area span {
        font-size: 0.7rem;
    }
    
    .touch-controls .row {
        --bs-gutter-x: 0.5rem;
    }
    
    .touch-controls .btn {
        font-size: 0.9rem;
        padding: 0.5rem 1rem;
        margin-bottom: 0.5rem;
    }
    
    .touch-points-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .touch-container {
        padding: 0.75rem;
    }
    
    .touch-test-area {
        height: 300px;
    }
    
    .test-overlay {
        padding: 1rem;
    }
    
    .test-overlay h3 {
        font-size: 1rem;
    }
    
    .test-overlay p {
        font-size: 0.9rem;
    }
    
    .touch-icon {
        font-size: 1.5rem;
    }
    
    .touch-indicator {
        width: 40px;
        height: 40px;
    }
    
    .touch-point {
        width: 25px;
        height: 25px;
    }
    
    .gesture-areas {
        padding: 0.25rem;
    }
    
    .gesture-area {
        min-height: 50px;
        padding: 0.25rem;
    }
    
    .gesture-area i {
        font-size: 1rem;
    }
    
    .gesture-area span {
        font-size: 0.6rem;
    }
    
    .touch-controls {
        padding: 0.75rem;
    }
    
    .touch-controls .btn {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
    
    .touch-stats {
        padding: 0.75rem;
    }
    
    .stat-card {
        padding: 0.75rem;
    }
    
    .stat-value {
        font-size: 1rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
    
    .touch-point-info,
    .gesture-item {
        padding: 0.5rem;
    }
    
    .point-label,
    .gesture-name {
        font-size: 0.8rem;
    }
    
    .point-coords,
    .point-pressure,
    .gesture-time {
        font-size: 0.7rem;
    }
}

/* Accessibility */
.touch-controls .btn:focus,
.gesture-area:focus {
    outline: 2px solid rgba(255, 255, 255, 0.8);
    outline-offset: 2px;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .touch-container {
        background: #000;
        border: 2px solid #fff;
    }
    
    .touch-test-area {
        background: #000;
        border: 2px solid #fff;
    }
    
    .test-overlay {
        background: #000;
        border: 1px solid #fff;
    }
    
    .gesture-area {
        background: #000;
        border: 2px solid #fff;
    }
    
    .gesture-area:hover {
        background: #333;
    }
    
    .gesture-area.active {
        background: #0f0;
        color: #000;
    }
    
    .touch-indicator {
        border-color: #fff;
        background: rgba(255, 255, 255, 0.5);
    }
    
    .touch-point {
        background: #fff;
        border-color: #000;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .touch-icon,
    .touch-indicator,
    .touch-point,
    .gesture-area,
    .stat-card,
    .touch-controls .btn {
        animation: none;
        transition: none;
    }
    
    .stat-card:hover,
    .touch-controls .btn:hover {
        transform: none;
    }
    
    .drawing-trail {
        animation: none;
        opacity: 0;
    }
}

/* Print Styles */
@media print {
    .touch-test-area,
    .touch-controls {
        display: none;
    }
    
    .touch-container {
        background: white;
        color: black;
    }
    
    .touch-stats {
        background: white;
        border: 1px solid #ccc;
    }
}
